Tce.RpcBinarySerializer.writeInt C# (CSharp) Method

writeInt() public static method

public static writeInt ( int value, BinaryWriter writer ) : void
value int
writer System.IO.BinaryWriter
return void
        public static void writeInt(int value, BinaryWriter writer)
        {
            writer.Write(IPAddress.HostToNetworkOrder(value));
        }

Usage Example

Example #1
0
 public bool marshall(Stream d)
 {
     try{
         BinaryWriter writer = new BinaryWriter(d);
         if (_props == null)
         {
             _props = new Dictionary <string, string>();
         }
         RpcBinarySerializer.writeInt(_props.Count, writer);
         foreach (KeyValuePair <string, string> kv in _props)
         {
             RpcBinarySerializer.writeString(kv.Key, writer);
             RpcBinarySerializer.writeString(kv.Value, writer);
         }
     }
     catch (Exception e) {
         return(false);
     }
     return(true);
 }
All Usage Examples Of Tce.RpcBinarySerializer::writeInt