Show / Hide Table of Contents

Class ResourceNameList<TName>

A list of resource names of a specific type, that delegates all operations to an underlying list of string-based resource names.

Inheritance
System.Object
ResourceNameList<TName>
Implements
System.Collections.Generic.IList<TName>
System.Collections.Generic.ICollection<TName>
System.Collections.Generic.IEnumerable<TName>
System.Collections.IEnumerable
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Google.Api.Gax
Assembly: Google.Api.Gax.dll
Syntax
public sealed class ResourceNameList<TName> : IList<TName>, ICollection<TName>, IEnumerable<TName>, IEnumerable where TName : class, IResourceName
Type Parameters
Name Description
TName

The type of the resource name contained in this list.

Constructors

ResourceNameList(IList<String>, Func<String, TName>)

Constructs a ResourceNameList<TName> from an underlying string-based list and a resource name parser.

Declaration
public ResourceNameList(IList<string> underlyingList, Func<string, TName> stringToName)
Parameters
Type Name Description
System.Collections.Generic.IList<System.String> underlyingList
System.Func<System.String, TName> stringToName

Properties

Count

Declaration
public int Count { get; }
Property Value
Type Description
System.Int32
Implements
System.Collections.Generic.ICollection<T>.Count

IsReadOnly

Declaration
public bool IsReadOnly { get; }
Property Value
Type Description
System.Boolean
Implements
System.Collections.Generic.ICollection<T>.IsReadOnly

Item[Int32]

Declaration
public TName this[int index] { get; set; }
Parameters
Type Name Description
System.Int32 index
Property Value
Type Description
TName
Implements
System.Collections.Generic.IList<T>.Item[System.Int32]

Methods

Add(TName)

Declaration
public void Add(TName item)
Parameters
Type Name Description
TName item
Implements
System.Collections.Generic.ICollection<T>.Add(T)

Add(IEnumerable<TName>)

Adds all items to this list.

Declaration
public void Add(IEnumerable<TName> items)
Parameters
Type Name Description
System.Collections.Generic.IEnumerable<TName> items

The items to add to this list.

Clear()

Declaration
public void Clear()
Implements
System.Collections.Generic.ICollection<T>.Clear()

Contains(TName)

Declaration
public bool Contains(TName item)
Parameters
Type Name Description
TName item
Returns
Type Description
System.Boolean
Implements
System.Collections.Generic.ICollection<T>.Contains(T)

CopyTo(TName[], Int32)

Declaration
public void CopyTo(TName[] array, int arrayIndex)
Parameters
Type Name Description
TName[] array
System.Int32 arrayIndex
Implements
System.Collections.Generic.ICollection<T>.CopyTo(T[], System.Int32)

GetEnumerator()

Declaration
public IEnumerator<TName> GetEnumerator()
Returns
Type Description
System.Collections.Generic.IEnumerator<TName>
Implements
System.Collections.Generic.IEnumerable<T>.GetEnumerator()

IndexOf(TName)

Declaration
public int IndexOf(TName item)
Parameters
Type Name Description
TName item
Returns
Type Description
System.Int32
Implements
System.Collections.Generic.IList<T>.IndexOf(T)

Insert(Int32, TName)

Declaration
public void Insert(int index, TName item)
Parameters
Type Name Description
System.Int32 index
TName item
Implements
System.Collections.Generic.IList<T>.Insert(System.Int32, T)

Remove(TName)

Declaration
public bool Remove(TName item)
Parameters
Type Name Description
TName item
Returns
Type Description
System.Boolean
Implements
System.Collections.Generic.ICollection<T>.Remove(T)

RemoveAt(Int32)

Declaration
public void RemoveAt(int index)
Parameters
Type Name Description
System.Int32 index
Implements
System.Collections.Generic.IList<T>.RemoveAt(System.Int32)

Explicit Interface Implementations

IEnumerable.GetEnumerator()

Declaration
IEnumerator IEnumerable.GetEnumerator()
Returns
Type Description
System.Collections.IEnumerator
Implements
System.Collections.IEnumerable.GetEnumerator()
Back to top