Class: Ondotori::WebAPI::StbWebAccess
- Defined in:
- lib/ondotori/webapi/webaccess.rb
Instance Attribute Summary collapse
-
#on_access ⇒ Object
writeonly
Sets the attribute on_access.
-
#params ⇒ Object
readonly
Returns the value of attribute params.
-
#uri ⇒ Object
readonly
Returns the value of attribute uri.
Instance Method Summary collapse
- #access(uri, params) ⇒ Object
-
#initialize(timeout, on_access) ⇒ StbWebAccess
constructor
A new instance of StbWebAccess.
Constructor Details
#initialize(timeout, on_access) ⇒ StbWebAccess
Returns a new instance of StbWebAccess.
18 19 20 21 |
# File 'lib/ondotori/webapi/webaccess.rb', line 18 def initialize(timeout, on_access) super timeout @on_access = on_access end |
Instance Attribute Details
#on_access=(value) ⇒ Object (writeonly)
Sets the attribute on_access
29 30 31 |
# File 'lib/ondotori/webapi/webaccess.rb', line 29 def on_access=(value) @on_access = value end |
#params ⇒ Object (readonly)
Returns the value of attribute params.
16 17 18 |
# File 'lib/ondotori/webapi/webaccess.rb', line 16 def params @params end |
#uri ⇒ Object (readonly)
Returns the value of attribute uri.
16 17 18 |
# File 'lib/ondotori/webapi/webaccess.rb', line 16 def uri @uri end |
Instance Method Details
#access(uri, params) ⇒ Object
23 24 25 26 27 |
# File 'lib/ondotori/webapi/webaccess.rb', line 23 def access(uri, params) @uri = uri @params = params @on_access.call(self) end |