Method Send
- Assembly
- Skyline.DataMiner.Core.InterAppCalls.Common.dll
Send(IConnection, int, int, int, IEnumerable<Type>)
Sends this call via SLNet to the specified DataMiner Agent ID/element ID/parameter ID without waiting on a reply.
void Send(IConnection connection, int agentId, int elementId, int parameterId, IEnumerable<Type> knownTypes)
Parameters
connection
IConnectionThe SLNet connection to use.
agentId
intDataMiner Agent ID of the destination.
elementId
intElement ID of the destination.
parameterId
intParameter ID of the destination.
knownTypes
IEnumerable<Type>List of all possible message classes. Needed for the default serializer.
Exceptions
- ArgumentNullException
connection
orknownTypes
isnull
.- ArgumentException
agentId
orelementId
orparameterId
is invalid.- InvalidOperationException
The state of the specified element is not "Active".
Send(IConnection, int, int, int, TimeSpan, IEnumerable<Type>, bool)
Sends this call via SLNet to the specific DataMiner Agent ID/element ID/parameter ID and waits until timeout for a single reply for each message.
IEnumerable<Message> Send(IConnection connection, int agentId, int elementId, int parameterId, TimeSpan timeout, IEnumerable<Type> knownTypes, bool allowBroker = true)
Parameters
connection
IConnectionThe SLNet connection to use.
agentId
intDataMiner Agent ID of the destination.
elementId
intElement ID of the destination.
parameterId
intParameter ID of the destination.
timeout
TimeSpanMaximum time to wait between received replies. Resets each time a reply is received.
knownTypes
IEnumerable<Type>List of all possible message classes. Needed for the default serializer.
allowBroker
bool(Optional) A boolean value indicating whether to allow replies via the broker. Messages replied via the broker have lower latency, but are limited in length, See MaxMessageSize. Default is
true
.
Returns
- IEnumerable<Message>
The responses.
Exceptions
- ArgumentNullException
connection
orknownTypes
isnull
.- ArgumentException
agentId
orelementId
orparameterId
is invalid.- ArgumentOutOfRangeException
timeout
is negative.- InvalidOperationException
The state of the specified element is not "Active".
- InvalidOperationException
ReturnAddress is not optional (see ReturnAddress).
- TimeoutException
One or more replies did not arrive within the specified
timeout
.
Send(IConnection, int, int, int, ISerializer)
Sends this call via SLNet to the specified DataMiner Agent ID/element ID/parameter ID without waiting on a reply.
void Send(IConnection connection, int agentId, int elementId, int parameterId, ISerializer serializer)
Parameters
connection
IConnectionThe SLNet connection to use.
agentId
intDataMiner Agent ID of the destination.
elementId
intElement ID of the destination.
parameterId
intParameter ID of the destination.
serializer
ISerializerA custom serializer to be used internally.
Exceptions
- ArgumentNullException
connection
orserializer
isnull
.- ArgumentException
agentId
orelementId
orparameterId
is invalid.- InvalidOperationException
The state of the specified element is not "Active".
Send(IConnection, int, int, int, TimeSpan, ISerializer, bool)
Sends this call via SLNet to the specific DataMiner Agent ID/element ID/parameter ID and waits until timeout for a single reply for each message.
IEnumerable<Message> Send(IConnection connection, int agentId, int elementId, int parameterId, TimeSpan timeout, ISerializer serializer, bool allowBroker = true)
Parameters
connection
IConnectionThe SLNet connection to use.
agentId
intDataMiner Agent ID of the destination.
elementId
intElement ID of the destination.
parameterId
intParameter ID of the destination.
timeout
TimeSpanMaximum time to wait between received replies. Resets each time a reply is received.
serializer
ISerializerA custom serializer to be used internally.
allowBroker
bool(Optional) A boolean value indicating whether to allow replies via the broker. Messages replied via the broker have lower latency, but are limited in length, See MaxMessageSize. Default is
true
.
Returns
- IEnumerable<Message>
The responses.
Exceptions
- ArgumentNullException
connection
orserializer
isnull
.- ArgumentException
agentId
orelementId
orparameterId
is invalid.- ArgumentOutOfRangeException
timeout
is negative.- InvalidOperationException
The state of the specified element is not "Active".
- InvalidOperationException
ReturnAddress is not optional (see ReturnAddress).
- TimeoutException
One or more replies did not arrive within the specified
timeout
.