Class: CASClient::ServiceTicket
- Inherits:
-
Object
- Object
- CASClient::ServiceTicket
- Defined in:
- lib/casclient/tickets.rb
Overview
Represents a CAS service ticket.
Direct Known Subclasses
Instance Attribute Summary collapse
-
#renew ⇒ Object
readonly
Returns the value of attribute renew.
-
#response ⇒ Object
Returns the value of attribute response.
-
#service ⇒ Object
readonly
Returns the value of attribute service.
-
#ticket ⇒ Object
readonly
Returns the value of attribute ticket.
Instance Method Summary collapse
- #has_been_validated? ⇒ Boolean
-
#initialize(ticket, service, renew = false) ⇒ ServiceTicket
constructor
A new instance of ServiceTicket.
- #is_valid? ⇒ Boolean
Constructor Details
#initialize(ticket, service, renew = false) ⇒ ServiceTicket
Returns a new instance of ServiceTicket.
7 8 9 10 11 |
# File 'lib/casclient/tickets.rb', line 7 def initialize(ticket, service, renew = false) @ticket = ticket @service = service @renew = renew end |
Instance Attribute Details
#renew ⇒ Object (readonly)
Returns the value of attribute renew.
4 5 6 |
# File 'lib/casclient/tickets.rb', line 4 def renew @renew end |
#response ⇒ Object
Returns the value of attribute response.
5 6 7 |
# File 'lib/casclient/tickets.rb', line 5 def response @response end |
#service ⇒ Object (readonly)
Returns the value of attribute service.
4 5 6 |
# File 'lib/casclient/tickets.rb', line 4 def service @service end |
#ticket ⇒ Object (readonly)
Returns the value of attribute ticket.
4 5 6 |
# File 'lib/casclient/tickets.rb', line 4 def ticket @ticket end |
Instance Method Details
#has_been_validated? ⇒ Boolean
17 18 19 |
# File 'lib/casclient/tickets.rb', line 17 def has_been_validated? not response.nil? end |
#is_valid? ⇒ Boolean
13 14 15 |
# File 'lib/casclient/tickets.rb', line 13 def is_valid? response.is_success? end |