Beispiel #1
0
        public static T Get <T>(ComplexBinaryReader reader)
        {
            if (typeof(IStructWrapper).IsAssignableFrom(typeof(T)))
            {
                return((T)Activator.CreateInstance(typeof(T), (object)reader));
            }

            return(Get <T>(reader.Reader));
        }
Beispiel #2
0
        public static T FromBinaryReaderFromPtr <T>(ComplexBinaryReader reader, long structPtr)
        {
            reader.Seek(structPtr, SeekOrigin.Begin);

            return(Get <T>(reader));
        }
Beispiel #3
0
 public static void Get <T>(ComplexBinaryReader reader, ref T destination)
 {
     Get(reader.Reader, ref destination);
 }