Class: Net::IMAP::XOauth2Authenticator
Relationships & Source Files | |
Inherits: | Object |
Defined in: | lib/net/imap/authenticators/xoauth2.rb |
Class Method Summary
- .new(user, oauth2_token) ⇒ XOauth2Authenticator constructor private
Instance Method Summary
Constructor Details
.new(user, oauth2_token) ⇒ XOauth2Authenticator
(private)
# File 'lib/net/imap/authenticators/xoauth2.rb', line 10
def initialize(user, oauth2_token) @user = user @oauth2_token = oauth2_token end
Instance Method Details
#build_oauth2_string(user, oauth2_token) (private)
[ GitHub ]# File 'lib/net/imap/authenticators/xoauth2.rb', line 15
def build_oauth2_string(user, oauth2_token) format("user=%s\1auth=Bearer %s\1\1", user, oauth2_token) end
#process(_data)
[ GitHub ]# File 'lib/net/imap/authenticators/xoauth2.rb', line 4
def process(_data) build_oauth2_string(@user, @oauth2_token) end