Class: Sharepoint::Session
- Inherits:
-
Object
- Object
- Sharepoint::Session
- Defined in:
- lib/sharepoint-session.rb
Defined Under Namespace
Classes: AuthenticationFailed, ConnexionToSharepointFailed, ConnexionToStsFailed, Error, UnknownAuthenticationError
Instance Attribute Summary collapse
-
#site ⇒ Object
Returns the value of attribute site.
Instance Method Summary collapse
- #authenticate(user, password, sts_url = nil) ⇒ Object
- #cookie ⇒ Object
-
#initialize(site) ⇒ Session
constructor
A new instance of Session.
Constructor Details
#initialize(site) ⇒ Session
Returns a new instance of Session.
39 40 41 |
# File 'lib/sharepoint-session.rb', line 39 def initialize site @site = site end |
Instance Attribute Details
#site ⇒ Object
Returns the value of attribute site.
37 38 39 |
# File 'lib/sharepoint-session.rb', line 37 def site @site end |
Instance Method Details
#authenticate(user, password, sts_url = nil) ⇒ Object
43 44 45 46 47 |
# File 'lib/sharepoint-session.rb', line 43 def authenticate user, password, sts_url = nil sts_url ||= MICROSOFT_STS_URL authenticate_to_sts user, password, sts_url get_access_token end |
#cookie ⇒ Object
49 50 51 |
# File 'lib/sharepoint-session.rb', line 49 def "FedAuth=#{@fed_auth};rtFa=#{@rtFa}" end |