一款简单易用的基础网络通讯组件库。

ValueCollectionT

表示一个值集合,包含多个 PlcValue 类型的值。

Definition

命名空间: TouchSocket.PlcBridges
程序集: TouchSocketPro.PlcBridges (在 TouchSocketPro.PlcBridges.dll 中) 版本:4.0.0-beta.143+5fcca7a4e70968794985dc3793adc50531308be6
C#
public abstract class ValueCollection<T> : List<T>
where T : PlcValue
Inheritance
Object    ListT    ValueCollectionT
Derived

类型参数

T
集合中的值类型,必须继承自 PlcValue

构造函数

ValueCollectionT 初始化 ValueCollectionT 类的新实例。
ValueCollectionT(IEnumerableT) 使用指定的值集合初始化 ValueCollectionT 类的新实例。

属性

CapacityGets or sets the total number of elements the internal data structure can hold without resizing.
(继承自 ListT。)
CountGets the number of elements contained in the ListT.
(继承自 ListT。)
ItemGets or sets the element at the specified index.
(继承自 ListT。)

方法

AddAdds an object to the end of the ListT.
(继承自 ListT。)
AddRangeAdds the elements of the specified collection to the end of the ListT.
(继承自 ListT。)
AsReadOnlyReturns a read-only ReadOnlyCollectionT wrapper for the current collection.
(继承自 ListT。)
BinarySearch(T)Searches the entire sorted ListT for an element using the default comparer and returns the zero-based index of the element.
(继承自 ListT。)
BinarySearch(T, IComparerT)Searches the entire sorted ListT for an element using the specified comparer and returns the zero-based index of the element.
(继承自 ListT。)
BinarySearch(Int32, Int32, T, IComparerT)Searches a range of elements in the sorted ListT for an element using the specified comparer and returns the zero-based index of the element.
(继承自 ListT。)
ClearRemoves all elements from the ListT.
(继承自 ListT。)
ContainsDetermines whether an element is in the ListT.
(继承自 ListT。)
ConvertAllTOutputConverts the elements in the current ListT to another type, and returns a list containing the converted elements.
(继承自 ListT。)
CopyTo(T)Copies the entire ListT to a compatible one-dimensional array, starting at the beginning of the target array.
(继承自 ListT。)
CopyTo(T, Int32)Copies the entire ListT to a compatible one-dimensional array, starting at the specified index of the target array.
(继承自 ListT。)
CopyTo(Int32, T, Int32, Int32)Copies a range of elements from the ListT to a compatible one-dimensional array, starting at the specified index of the target array.
(继承自 ListT。)
EnsureCapacityEnsures that the capacity of this list is at least the specified capacity. If the current capacity is less than capacity, it is successively increased to twice the current capacity until it is at least the specified capacity.
(继承自 ListT。)
EqualsDetermines whether the specified object is equal to the current object.
(继承自 Object。)
ExistsDetermines whether the ListT contains elements that match the conditions defined by the specified predicate.
(继承自 ListT。)
FinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(继承自 Object。)
FindSearches for an element that matches the conditions defined by the specified predicate, and returns the first occurrence within the entire ListT.
(继承自 ListT。)
FindAllRetrieves all the elements that match the conditions defined by the specified predicate.
(继承自 ListT。)
FindIndex(PredicateT)Searches for an element that matches the conditions defined by the specified predicate, and returns the zero-based index of the first occurrence within the entire ListT.
(继承自 ListT。)
FindIndex(Int32, PredicateT)Searches for an element that matches the conditions defined by the specified predicate, and returns the zero-based index of the first occurrence within the range of elements in the ListT that extends from the specified index to the last element.
(继承自 ListT。)
FindIndex(Int32, Int32, PredicateT)Searches for an element that matches the conditions defined by the specified predicate, and returns the zero-based index of the first occurrence within the range of elements in the ListT that starts at the specified index and contains the specified number of elements.
(继承自 ListT。)
FindLastSearches for an element that matches the conditions defined by the specified predicate, and returns the last occurrence within the entire ListT.
(继承自 ListT。)
FindLastIndex(PredicateT)Searches for an element that matches the conditions defined by the specified predicate, and returns the zero-based index of the last occurrence within the entire ListT.
(继承自 ListT。)
FindLastIndex(Int32, PredicateT)Searches for an element that matches the conditions defined by the specified predicate, and returns the zero-based index of the last occurrence within the range of elements in the ListT that extends from the first element to the specified index.
(继承自 ListT。)
FindLastIndex(Int32, Int32, PredicateT)Searches for an element that matches the conditions defined by the specified predicate, and returns the zero-based index of the last occurrence within the range of elements in the ListT that contains the specified number of elements and ends at the specified index.
(继承自 ListT。)
ForEachPerforms the specified action on each element of the ListT.
(继承自 ListT。)
GetEnumeratorReturns an enumerator that iterates through the ListT.
(继承自 ListT。)
GetHashCodeServes as the default hash function.
(继承自 Object。)
GetRangeCreates a shallow copy of a range of elements in the source ListT.
(继承自 ListT。)
GetTypeGets the Type of the current instance.
(继承自 Object。)
IndexOf(T)Searches for the specified object and returns the zero-based index of the first occurrence within the entire ListT.
(继承自 ListT。)
IndexOf(T, Int32)Searches for the specified object and returns the zero-based index of the first occurrence within the range of elements in the ListT that extends from the specified index to the last element.
(继承自 ListT。)
IndexOf(T, Int32, Int32)Searches for the specified object and returns the zero-based index of the first occurrence within the range of elements in the ListT that starts at the specified index and contains the specified number of elements.
(继承自 ListT。)
InsertInserts an element into the ListT at the specified index.
(继承自 ListT。)
InsertRangeInserts the elements of a collection into the ListT at the specified index.
(继承自 ListT。)
LastIndexOf(T)Searches for the specified object and returns the zero-based index of the last occurrence within the entire ListT.
(继承自 ListT。)
LastIndexOf(T, Int32)Searches for the specified object and returns the zero-based index of the last occurrence within the range of elements in the ListT that extends from the first element to the specified index.
(继承自 ListT。)
LastIndexOf(T, Int32, Int32)Searches for the specified object and returns the zero-based index of the last occurrence within the range of elements in the ListT that contains the specified number of elements and ends at the specified index.
(继承自 ListT。)
MemberwiseCloneCreates a shallow copy of the current Object.
(继承自 Object。)
RemoveRemoves the first occurrence of a specific object from the ListT.
(继承自 ListT。)
RemoveAllRemoves all the elements that match the conditions defined by the specified predicate.
(继承自 ListT。)
RemoveAtRemoves the element at the specified index of the ListT.
(继承自 ListT。)
RemoveRangeRemoves a range of elements from the ListT.
(继承自 ListT。)
ReverseReverses the order of the elements in the entire ListT.
(继承自 ListT。)
Reverse(Int32, Int32)Reverses the order of the elements in the specified range.
(继承自 ListT。)
SortSorts the elements in the entire ListT using the default comparer.
(继承自 ListT。)
Sort(ComparisonT)Sorts the elements in the entire ListT using the specified ComparisonT.
(继承自 ListT。)
Sort(IComparerT)Sorts the elements in the entire ListT using the specified comparer.
(继承自 ListT。)
Sort(Int32, Int32, IComparerT)Sorts the elements in a range of elements in ListT using the specified comparer.
(继承自 ListT。)
ToArrayCopies the elements of the ListT to a new array.
(继承自 ListT。)
ToStringReturns a string that represents the current object.
(继承自 Object。)
TrimExcessSets the capacity to the actual number of elements in the ListT, if that number is less than a threshold value.
(继承自 ListT。)
TrueForAllDetermines whether every element in the ListT matches the conditions defined by the specified predicate.
(继承自 ListT。)

扩展方法

Map 将源对象的属性映射到目标对象的属性中。
(由 Mapper 定义。)
Map 将源对象映射到目标类型的实例。
(由 Mapper 定义。)
MapTTarget 将源对象映射到指定目标类型的新实例。
(由 Mapper 定义。)
ToJsonString 转换为Json
(由 SerializeConvert 定义。)

显式接口实现

IListAddAdds an item to the IList.
(继承自 ListT。)
IListContainsDetermines whether the IList contains a specific value.
(继承自 ListT。)
ICollectionCopyToCopies the elements of the ICollection to an Array, starting at a particular Array index.
(继承自 ListT。)
IEnumerableTGetEnumeratorReturns an enumerator that iterates through a collection.
(继承自 ListT。)
IEnumerableGetEnumeratorReturns an enumerator that iterates through a collection.
(继承自 ListT。)
IListIndexOfDetermines the index of a specific item in the IList.
(继承自 ListT。)
IListInsertInserts an item to the IList at the specified index.
(继承自 ListT。)
IListIsFixedSizeGets a value indicating whether the IList has a fixed size.
(继承自 ListT。)
ICollectionTIsReadOnlyGets a value indicating whether the ICollectionT is read-only.
(继承自 ListT。)
IListIsReadOnlyGets a value indicating whether the IList is read-only.
(继承自 ListT。)
ICollectionIsSynchronizedGets a value indicating whether access to the ICollection is synchronized (thread safe).
(继承自 ListT。)
IListItemGets or sets the element at the specified index.
(继承自 ListT。)
IListRemoveRemoves the first occurrence of a specific object from the IList.
(继承自 ListT。)
ICollectionSyncRootGets an object that can be used to synchronize access to the ICollection.
(继承自 ListT。)

参见