Example #1
0
 public override void WriteCollectionBegin(TCollection collection)
 {
     WriteByte((byte)collection.ElementType);
     WriteI32(collection.Count);
 }
Example #2
0
        public override TCollection ReadCollectionBegin()
        {
            TCollection collection = new TCollection();
            collection.ElementType = (TType)ReadByte();
            collection.Count = ReadI32();

            return collection;
        }
Example #3
0
 /**
 * Write a collection header.
 */
 public override void WriteCollectionBegin(TCollection collection)
 {
     WriteCollectionBegin(collection.ElementType, collection.Count);
 }
Example #4
0
 public override void WriteCollectionBegin(TCollection collection)
 {
     WriteJSONArrayStart();
     WriteJSONString(GetTypeNameForTypeID(collection.ElementType));
     WriteJSONInteger(collection.Count);
 }
Example #5
0
 public override TCollection ReadCollectionBegin()
 {
     TCollection collection = new TCollection();
     ReadJSONArrayStart();
     collection.ElementType = GetTypeIDForTypeName(ReadJSONString(false));
     collection.Count = (int)ReadJSONInteger();
     return collection;
 }
Example #6
0
 public abstract void WriteCollectionBegin(TCollection collection);