public void Deserialize(IPofReader reader) { invocationId = reader.ReadU32(0); serviceGuid = reader.ReadGuid(1); methodName = reader.ReadString(2); genericArguments = reader.ReadObject <PortableObjectBox>(3); methodArguments = reader.ReadObject <PortableObjectBox>(4); }
public bool TryConvertFromDataTransferObject <T>(PortableObjectBox dto, out T methodArguments) { using (var ms = streamFactory.CreateMemoryStream(dto.Buffer, dto.Offset, dto.Length)) { try { methodArguments = (T)pofSerializer.Deserialize(ms.Reader); return(true); } catch (TypeNotFoundException) { methodArguments = default(T); return(false); } } }
public X2XServiceInvocation( uint invocationId, Guid serviceGuid, string methodName, PortableObjectBox genericArguments, PortableObjectBox methodArguments ) { this.invocationId = invocationId; this.serviceGuid = serviceGuid; this.methodName = methodName; this.genericArguments = genericArguments; this.methodArguments = methodArguments; }
public void Deserialize(IPofReader reader) { invocationId = reader.ReadU32(0); payloadBox = reader.ReadObject <PortableObjectBox>(1); }
public X2XInvocationResult(uint invocationId, PortableObjectBox payloadBox) { this.invocationId = invocationId; this.payloadBox = payloadBox; }
public Task SendServiceInvocationAsync(uint invocationId, Guid serviceGuid, string methodName, PortableObjectBox genericArgumentsDto, PortableObjectBox methodArgumentsDto) { var message = new X2XServiceInvocation(invocationId, serviceGuid, methodName, genericArgumentsDto, methodArgumentsDto); pofStreamWriter.Write(message); return(Task.FromResult <object>(null)); }