C# Class OpenHome.Net.ControlPoint.Invocation

Utility class used to execute a single action. Only intended for use by auto-generated proxies.
Exibir arquivo Open project: openhome/ohNet Class Usage Examples

Public Methods

Method Description
AddInput ( Argument aArgument ) : void

Add an input argument to an invocation

AddOutput ( Argument aArgument ) : void

Add an output argument to an invocation

Error ( IntPtr aHandle, uint &aErrorCode, string &aErrorDesc ) : bool

Check whether the invocation failed

Only intended for use in the invocation complete callback

OutputBinary ( IntPtr aHandle, uint aIndex ) : byte[]

Utility to retrieve the value of a binary type output argument

Must only be called once per output argument. (The first call extracts the binary data from the underlying native object so later calls would return an empty string.)

OutputBool ( IntPtr aHandle, uint aIndex ) : bool

Utility to retrieve the value of a boolean type output argument

OutputInt ( IntPtr aHandle, uint aIndex ) : int

Utility to retrieve the value of an integer type output argument

OutputString ( IntPtr aHandle, uint aIndex ) : String

Utility to retrieve the value of a string type output argument

Must only be called once per output argument. (The first call extracts the string data from the underlying native object so later calls would return an empty string.)

OutputUint ( IntPtr aHandle, uint aIndex ) : uint

Utility to retrieve the value of an unsigned integer type output argument

Private Methods

Method Description
AsyncComplete ( IntPtr aPtr, IntPtr aAsyncHandle ) : void
CpInvocationAddInput ( IntPtr aInvocation, IntPtr aArgument ) : void
CpInvocationAddOutput ( IntPtr aInvocation, IntPtr aArgument ) : void
CpInvocationError ( IntPtr aInvocation, uint &aErrorCode, IntPtr &aErrorDesc ) : uint
CpInvocationGetOutputBinary ( IntPtr aInvocation, uint aIndex, IntPtr &aData, uint &aLen ) : void
CpInvocationGetOutputString ( IntPtr aInvocation, uint aIndex, IntPtr &aData, uint &aLen ) : void
CpInvocationOutputBool ( IntPtr aInvocation, uint aIndex ) : uint
CpInvocationOutputInt ( IntPtr aInvocation, uint aIndex ) : int
CpInvocationOutputUint ( IntPtr aInvocation, uint aIndex ) : uint
CpServiceInvocation ( IntPtr aService, IntPtr aAction, CpProxy aCallback, IntPtr aPtr ) : IntPtr
Handle ( ) : IntPtr
Invocation ( CpService aService, IntPtr aAction, CpProxy aCallback ) : System

Constructor. Not intended for external use (use CpService.Invocation instead)

OhNetFree ( IntPtr aPtr ) : void

Method Details

AddInput() public method

Add an input argument to an invocation
public AddInput ( Argument aArgument ) : void
aArgument Argument Input argument being added. Ownership passes to the invocation
return void

AddOutput() public method

Add an output argument to an invocation
public AddOutput ( Argument aArgument ) : void
aArgument Argument Output argument being added. Ownership passes to the invocation
return void

Error() public static method

Check whether the invocation failed
Only intended for use in the invocation complete callback
public static Error ( IntPtr aHandle, uint &aErrorCode, string &aErrorDesc ) : bool
aHandle System.IntPtr
aErrorCode uint
aErrorDesc string
return bool

OutputBinary() public static method

Utility to retrieve the value of a binary type output argument
Must only be called once per output argument. (The first call extracts the binary data from the underlying native object so later calls would return an empty string.)
public static OutputBinary ( IntPtr aHandle, uint aIndex ) : byte[]
aHandle System.IntPtr Invocation handle
aIndex uint Zero-based index into array of output arguments. /// Must refer to an ArgumentString.
return byte[]

OutputBool() public static method

Utility to retrieve the value of a boolean type output argument
public static OutputBool ( IntPtr aHandle, uint aIndex ) : bool
aHandle System.IntPtr Invocation handle
aIndex uint Zero-based index into array of output arguments. /// Must refer to an ArgumentBool.
return bool

OutputInt() public static method

Utility to retrieve the value of an integer type output argument
public static OutputInt ( IntPtr aHandle, uint aIndex ) : int
aHandle System.IntPtr Invocation handle
aIndex uint Zero-based index into array of output arguments. /// Must refer to an ArgumentInt.
return int

OutputString() public static method

Utility to retrieve the value of a string type output argument
Must only be called once per output argument. (The first call extracts the string data from the underlying native object so later calls would return an empty string.)
public static OutputString ( IntPtr aHandle, uint aIndex ) : String
aHandle System.IntPtr Invocation handle
aIndex uint Zero-based index into array of output arguments. /// Must refer to an ArgumentString.
return String

OutputUint() public static method

Utility to retrieve the value of an unsigned integer type output argument
public static OutputUint ( IntPtr aHandle, uint aIndex ) : uint
aHandle System.IntPtr Invocation handle
aIndex uint Zero-based index into array of output arguments. /// Must refer to an ArgumentUint.
return uint