Home > @i2analyze/i2connect > services > IResult > getEntity
services.IResult.getEntity() method
Gets a previously added entity record from the result, whose identifier is a string that you provided or a source identifier that you created.
Signature:
getEntity<TEntityType extends schema.IEntityType>(type: TEntityType, id: records.ResultRecordIdType): records.IResultEntityRecord<TEntityType, records.ResultRecordIdType> | undefined;
Introduced: API version 2.0
Type Parameters
Parameter | Type | Description |
---|---|---|
TEntityType | extends schema.IEntityType | The type of the entity record. |
Parameters
Parameter | Type | Description |
---|---|---|
type | TEntityType | The entity type of the record. |
id | records.ResultRecordIdType | The identifier or source identifier of the record. |
Returns:
records.IResultEntityRecord<TEntityType, records.ResultRecordIdType> | undefined
The entity record that was previously added to the result, or undefined
if it was not previously added.