Class SyncList<T>
Inheritance
System.Object
Inherited Members
Show
Syntax
public class SyncList<T> : IList<T>, ICollection<T>, IReadOnlyList<T>, IReadOnlyCollection<T>, IEnumerable<T>, IEnumerable, ISyncObject
Type Parameters
Name | Description |
---|---|
T |
Constructors
SyncList()
Declaration
public SyncList()
SyncList(IEqualityComparer<T>)
Declaration
public SyncList(IEqualityComparer<T> comparer)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEqualityComparer<T> | comparer |
SyncList(IList<T>, IEqualityComparer<T>)
Declaration
public SyncList(IList<T> objects, IEqualityComparer<T> comparer = null)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IList<T> | objects | |
System.Collections.Generic.IEqualityComparer<T> | comparer |
Properties
Count
Declaration
public int Count { get; }
IsReadOnly
Declaration
public bool IsReadOnly { get; }
IsDirty
Declaration
public bool IsDirty { get; }
Item[Int32]
Declaration
public T this[int i] { get; set; }
Methods
ISyncObject.SetShouldSyncFrom(Boolean)
Declaration
void ISyncObject.SetShouldSyncFrom(bool shouldSync)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | shouldSync |
ISyncObject.SetNetworkBehaviour(NetworkBehaviour)
Declaration
void ISyncObject.SetNetworkBehaviour(NetworkBehaviour networkBehaviour)
Parameters
Type | Name | Description |
---|---|---|
Mirage.NetworkBehaviour | networkBehaviour |
Flush()
Declaration
public void Flush()
Reset()
Declaration
public void Reset()
OnSerializeAll(NetworkWriter)
Declaration
public void OnSerializeAll(NetworkWriter writer)
Parameters
Type | Name | Description |
---|---|---|
Mirage.Serialization.NetworkWriter | writer |
OnSerializeDelta(NetworkWriter)
Declaration
public void OnSerializeDelta(NetworkWriter writer)
Parameters
Type | Name | Description |
---|---|---|
Mirage.Serialization.NetworkWriter | writer |
OnDeserializeAll(NetworkReader)
Declaration
public void OnDeserializeAll(NetworkReader reader)
Parameters
Type | Name | Description |
---|---|---|
Mirage.Serialization.NetworkReader | reader |
OnDeserializeDelta(NetworkReader)
Declaration
public void OnDeserializeDelta(NetworkReader reader)
Parameters
Type | Name | Description |
---|---|---|
Mirage.Serialization.NetworkReader | reader |
Add(T)
Declaration
public void Add(T item)
Parameters
Type | Name | Description |
---|---|---|
T | item |
AddRange(IEnumerable<T>)
Declaration
public void AddRange(IEnumerable<T> range)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<T> | range |
Clear()
Declaration
public void Clear()
Contains(T)
Declaration
public bool Contains(T item)
Parameters
Type | Name | Description |
---|---|---|
T | item |
Returns
Type | Description |
---|---|
System.Boolean |
CopyTo(T[], Int32)
Declaration
public void CopyTo(T[] array, int arrayIndex)
Parameters
Type | Name | Description |
---|---|---|
{T}[] | array | |
System.Int32 | arrayIndex |
IndexOf(T)
Declaration
public int IndexOf(T item)
Parameters
Type | Name | Description |
---|---|---|
T | item |
Returns
Type | Description |
---|---|
System.Int32 |
FindIndex(Predicate<T>)
Declaration
public int FindIndex(Predicate<T> match)
Parameters
Type | Name | Description |
---|---|---|
System.Predicate<T> | match |
Returns
Type | Description |
---|---|
System.Int32 |
Find(Predicate<T>)
Declaration
public T Find(Predicate<T> match)
Parameters
Type | Name | Description |
---|---|---|
System.Predicate<T> | match |
Returns
Type | Description |
---|---|
T |
FindAll(Predicate<T>)
Declaration
public List<T> FindAll(Predicate<T> match)
Parameters
Type | Name | Description |
---|---|---|
System.Predicate<T> | match |
Returns
Type | Description |
---|---|
System.Collections.Generic.List<T> |
Insert(Int32, T)
Declaration
public void Insert(int index, T item)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index | |
T | item |
InsertRange(Int32, IEnumerable<T>)
Declaration
public void InsertRange(int index, IEnumerable<T> range)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index | |
System.Collections.Generic.IEnumerable<T> | range |
Remove(T)
Declaration
public bool Remove(T item)
Parameters
Type | Name | Description |
---|---|---|
T | item |
Returns
Type | Description |
---|---|
System.Boolean |
RemoveAt(Int32)
Declaration
public void RemoveAt(int index)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index |
RemoveAll(Predicate<T>)
Declaration
public int RemoveAll(Predicate<T> match)
Parameters
Type | Name | Description |
---|---|---|
System.Predicate<T> | match |
Returns
Type | Description |
---|---|
System.Int32 |
SetItemDirty(T)
Can be used to set item dirty manually. should be used with classes to avoid having to clear field first Will invoke OnSet
Declaration
public void SetItemDirty(T item)
Parameters
Type | Name | Description |
---|---|---|
T | item |
SetItemDirtyAt(Int32)
Can be used to set item dirty manually. should be used with classes to avoid having to clear field first
Declaration
public void SetItemDirtyAt(int index)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index |
GetEnumerator()
Declaration
public SyncList<T>.Enumerator GetEnumerator()
Returns
Type | Description |
---|---|
Mirage.Collections.SyncList.Enumerator<> |
IEnumerable<T>.GetEnumerator()
Declaration
IEnumerator<T> IEnumerable<T>.GetEnumerator()
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerator<T> |
IEnumerable.GetEnumerator()
Declaration
IEnumerator IEnumerable.GetEnumerator()
Returns
Type | Description |
---|---|
System.Collections.IEnumerator |