Bexel Manager API Documentation
Bexel.Api.IReadOnlyElementCollection< TElement > Interface Template Reference

Represents a read-only collection of Bexel.Api.Elements. More...

Inheritance diagram for Bexel.Api.IReadOnlyElementCollection< TElement >:
IReadOnlyCollection Bexel.Api.ReadOnlyElementCollection< TElement > Bexel.Api.BuildingElements Bexel.Api.BuildingStoreyElements Bexel.Api.CategoryElements Bexel.Api.ElementSourceElements Bexel.Api.ElementSystemElements Bexel.Api.FamilyElements Bexel.Api.ProjectElements Bexel.Api.SelectedElementsCollection Bexel.Api.SelectionSets.SelectionSetElements Bexel.Api.SelectionSets.SelectionSetFolderElements

Public Member Functions

TElement GetElementByID (ElementID id)
 Retrieves the element with the specified ID. More...
 
TElement GetElementByID (int internalID)
 Retrieves the element with the specified internal ID. More...
 
TElement GetElementByID (string uniqueID)
 Retrieves the element with the specified unique ID. More...
 
TElement GetElementByID (Guid uniqueID)
 Retrieves the element with the specified unique ID. More...
 
IEnumerable< TElement > GetElementsByID (string uniqueID)
 Retrieves the elements with the specified unique ID. More...
 
IEnumerable< TElement > GetElementsByID (Guid uniqueID)
 Retrieves the elements with the specified unique ID. More...
 
bool ContainsKey (ElementID id)
 Determines whether the collection contains the element with the specified ID. More...
 
bool ContainsKey (int internalID)
 Determines whether the collection contains the element with the specified internal ID. More...
 

Properties

TElement this[ElementID id] [get]
 Retrieves the element with the specified ID. More...
 
TElement this[int internalID] [get]
 Retrieves the element with the specified internal ID. More...
 

Detailed Description

Represents a read-only collection of Bexel.Api.Elements.

Type Constraints
TElement :Element 

Member Function Documentation

◆ ContainsKey() [1/2]

bool Bexel.Api.IReadOnlyElementCollection< TElement >.ContainsKey ( ElementID  id)

Determines whether the collection contains the element with the specified ID.

Parameters
idID of the element.
Returns
True if element with the specified ID exists, False otherwise.

Implemented in Bexel.Api.ReadOnlyElementCollection< TElement >.

◆ ContainsKey() [2/2]

bool Bexel.Api.IReadOnlyElementCollection< TElement >.ContainsKey ( int  internalID)

Determines whether the collection contains the element with the specified internal ID.

Parameters
internalIDInternal ID of the element.
Returns
True if element with the specified internal ID exists, False otherwise.

Implemented in Bexel.Api.ReadOnlyElementCollection< TElement >.

◆ GetElementByID() [1/4]

TElement Bexel.Api.IReadOnlyElementCollection< TElement >.GetElementByID ( ElementID  id)

Retrieves the element with the specified ID.

Parameters
idID of the element.
Returns
An element with the specified ID, null if no such element exists within the collection.

Implemented in Bexel.Api.ReadOnlyElementCollection< TElement >.

◆ GetElementByID() [2/4]

TElement Bexel.Api.IReadOnlyElementCollection< TElement >.GetElementByID ( int  internalID)

Retrieves the element with the specified internal ID.

Parameters
internalIDInternal ID of the element.
Returns
An element with the specified internal ID, null if no such element exists within the collection.

Implemented in Bexel.Api.ReadOnlyElementCollection< TElement >.

◆ GetElementByID() [3/4]

TElement Bexel.Api.IReadOnlyElementCollection< TElement >.GetElementByID ( string  uniqueID)

Retrieves the element with the specified unique ID.

Parameters
uniqueIDUnique ID of the element.
Returns
An element with the specified unique ID, null if no such element exists within the collection.

If multiple elements with the same unique ID exist, the first element will be returned.

Exceptions
System.ArgumentNullExceptionuniqueID is null.
System.FormatExceptionuniqueID is not a valid GUID format.

Implemented in Bexel.Api.ReadOnlyElementCollection< TElement >.

◆ GetElementByID() [4/4]

TElement Bexel.Api.IReadOnlyElementCollection< TElement >.GetElementByID ( Guid  uniqueID)

Retrieves the element with the specified unique ID.

Parameters
uniqueIDUnique ID of the element.
Returns
An element with the specified unique ID, null if no such element exists within the collection.

If multiple elements with the same unique ID exist, the first element will be returned.

Implemented in Bexel.Api.ReadOnlyElementCollection< TElement >.

◆ GetElementsByID() [1/2]

IEnumerable<TElement> Bexel.Api.IReadOnlyElementCollection< TElement >.GetElementsByID ( string  uniqueID)

Retrieves the elements with the specified unique ID.

Parameters
uniqueIDUnique ID of the element.
Returns
All elements with the specified unique ID, empty collection if no such elements exist within the collection.

Implemented in Bexel.Api.ReadOnlyElementCollection< TElement >.

◆ GetElementsByID() [2/2]

IEnumerable<TElement> Bexel.Api.IReadOnlyElementCollection< TElement >.GetElementsByID ( Guid  uniqueID)

Retrieves the elements with the specified unique ID.

Parameters
uniqueIDUnique ID of the element.
Returns
All elements with the specified unique ID, empty collection if no such elements exist within the collection.

Implemented in Bexel.Api.ReadOnlyElementCollection< TElement >.

Property Documentation

◆ this[ElementID id]

TElement Bexel.Api.IReadOnlyElementCollection< TElement >.this[ElementID id]
get

Retrieves the element with the specified ID.

Parameters
idID of the element.
Returns
An element with the specified ID.
Exceptions
System.Collections.Generic.KeyNotFoundExceptionNo element with the specified ID exists within the collection.

◆ this[int internalID]

TElement Bexel.Api.IReadOnlyElementCollection< TElement >.this[int internalID]
get

Retrieves the element with the specified internal ID.

Parameters
internalIDInternal ID of the element.
Returns
An element with the specified internal ID.
Exceptions
System.Collections.Generic.KeyNotFoundExceptionNo element with the specified internal ID exists within the collection.