public static OperationResult Decode(IByteReader stream) { OperationResult decodedOperationResult = new OperationResult(); decodedOperationResult.Discriminant = OperationResultCode.Decode(stream); switch (decodedOperationResult.Discriminant.InnerValue) { case OperationResultCode.OperationResultCodeEnum.opINNER: decodedOperationResult.Tr = OperationResultTr.Decode(stream); break; default: break; } return(decodedOperationResult); }
public static OperationResult Decode(XdrDataInputStream stream) { OperationResult decodedOperationResult = new OperationResult(); OperationResultCode discriminant = OperationResultCode.Decode(stream); decodedOperationResult.Discriminant = discriminant; switch (decodedOperationResult.Discriminant.InnerValue) { case OperationResultCode.OperationResultCodeEnum.opINNER: decodedOperationResult.Tr = OperationResultTr.Decode(stream); break; } return(decodedOperationResult); }