Class: NWRFC::FunctionCall
- Inherits:
-
DataContainer
- Object
- DataContainer
- NWRFC::FunctionCall
- Defined in:
- lib/nwrfc.rb
Instance Attribute Summary collapse
-
#connection ⇒ Object
readonly
Returns the value of attribute connection.
-
#desc ⇒ Object
readonly
Returns the value of attribute desc.
-
#function ⇒ Object
readonly
Returns the value of attribute function.
-
#handle ⇒ Object
readonly
Returns the value of attribute handle.
Instance Method Summary collapse
-
#initialize(function) ⇒ FunctionCall
constructor
A new instance of FunctionCall.
- #invoke ⇒ Object
Methods inherited from DataContainer
#[], #[]=, #member_metadata, #value_to_date, #value_to_time
Constructor Details
#initialize(function) ⇒ FunctionCall
Returns a new instance of FunctionCall.
181 182 183 184 185 186 187 188 |
# File 'lib/nwrfc.rb', line 181 def initialize(function) @error = NWRFCLib::RFCError.new @function = function @connection = function.connection @handle = NWRFCLib.create_function(@function.desc, @error.to_ptr) @desc = function.desc NWRFC.check_error(@error) end |
Instance Attribute Details
#connection ⇒ Object (readonly)
Returns the value of attribute connection.
179 180 181 |
# File 'lib/nwrfc.rb', line 179 def connection @connection end |
#desc ⇒ Object (readonly)
Returns the value of attribute desc.
179 180 181 |
# File 'lib/nwrfc.rb', line 179 def desc @desc end |
#function ⇒ Object (readonly)
Returns the value of attribute function.
179 180 181 |
# File 'lib/nwrfc.rb', line 179 def function @function end |
#handle ⇒ Object (readonly)
Returns the value of attribute handle.
179 180 181 |
# File 'lib/nwrfc.rb', line 179 def handle @handle end |
Instance Method Details
#invoke ⇒ Object
190 191 192 193 |
# File 'lib/nwrfc.rb', line 190 def invoke rc = NWRFCLib.invoke(@connection.handle, @handle, @error.to_ptr) NWRFC.check_error(@error) if rc > 0 end |