protected override ServiceResult Call(
ISystemContext context,
NodeId objectId,
IList<object> inputArguments,
IList<object> outputArguments)
{
if (OnCall == null)
{
return base.Call(context, objectId, inputArguments, outputArguments);
}
ServiceResult result = null;
byte[] communicationRelationId = (byte[])inputArguments[0];
uint serviceId = (uint)inputArguments[1];
string blockTag = (string)outputArguments[0];
byte[] alarmEventData = (byte[])outputArguments[1];
NodeId alarmEventType = (NodeId)outputArguments[2];
DateTime timeStamp = (DateTime)outputArguments[3];
uint delayForNextCall = (uint)outputArguments[4];
object serviceError = (object)outputArguments[5];
if (OnCall != null)
{
result = OnCall(
context,
this,
objectId,
communicationRelationId,
serviceId,
ref blockTag,
ref alarmEventData,
ref alarmEventType,
ref timeStamp,
ref delayForNextCall,
ref serviceError);
}
outputArguments[0] = blockTag;
outputArguments[1] = alarmEventData;
outputArguments[2] = alarmEventType;
outputArguments[3] = timeStamp;
outputArguments[4] = delayForNextCall;
outputArguments[5] = serviceError;
return result;
}