Version 2.1.0.0

ListFormatter<T> class

Namespace: Sirenix.Serialization
Assembly: Sirenix.Serialization
public class ListFormatter<T> : BaseFormatter<List<T>>, IFormatter<List<T>>, IFormatter
Custom generic formatter for the generic type definition System.Collections.Generic.List<T>.
Inheritance
  • System.Object
  • BaseFormatter<System.Collections.Generic.List<T>>
  • ListFormatter<T>

Type Parameters

T

The element type of the formatted list.

Constructors

ListFormatter()
public ListFormatter()

Methods

DeserializeImplementation(ref List<T>, IDataReader)
Provides the actual implementation for deserializing a value of type .
protected override void DeserializeImplementation(ref List<T> value, IDataReader reader)
Parameters
System.Collections.Generic.List<T> value

The uninitialized value to serialize into. This value will have been created earlier using GetUninitializedObject().

Sirenix.Serialization.IDataReader reader

The reader to deserialize with.

GetUninitializedObject()
Returns null.
protected override List<T> GetUninitializedObject()
Returns
System.Collections.Generic.List<T>

A null value.

SerializeImplementation(ref List<T>, IDataWriter)
Provides the actual implementation for serializing a value of type .
protected override void SerializeImplementation(ref List<T> value, IDataWriter writer)
Parameters
System.Collections.Generic.List<T> value

The value to serialize.

Sirenix.Serialization.IDataWriter writer

The writer to serialize with.

This website is brand new and built with the Odin 2.1 beta in mind. This means you might discover some features such as attribute expressions that are only available in the beta.

You can download the 2.1 beta from here and read the patch-notes here.