Esempio n. 1
0
        public override bool Equals(object?obj)
        {
            if (this == obj)
            {
                return(true);
            }
            if (obj == null || GetType() != obj.GetType())
            {
                return(false);
            }

            SimpleSerializedObject <T> that = (obj as SimpleSerializedObject <T>) !;

            return(_data !.Equals(that._data) &&
                   _type.Equals(that._type) &&
                   _dataType == that._dataType);
        }
Esempio n. 2
0
 /// <summary>
 /// Construct an instance with given {@code bytes} representing the serialized form of a {@link MetaData}
 /// instance.
 /// </summary>
 /// <param name="data">data representing the serialized form of a {@link MetaData} instance.</param>
 /// <param name="dataType">The type of data</param>
 public SerializedMetaData(T data, Type dataType)
 {
     _delegate = new SimpleSerializedObject <T>(data, dataType, MetadataClassName, null);
 }