Type Alias: EntityLookup
type EntityLookup = {
linkage?: UUID[];
} &
| {
byName: | string
| ((params: {
id: string;
event: IngestEvent;
}) => string);
byUuid?: never;
resolve?: never;
}
| {
byUuid: EntityMap;
byName?: never;
resolve?: never;
}
| {
resolve: (params: {
id: string;
event: IngestEvent;
}) =>
| UUID
| MappedEntity
| null
| Promise<UUID | MappedEntity | null>;
byName?: never;
byUuid?: never;
};
Defined in: livelink.clients/livelink.agent/sources/data/EventMapping.ts:65
How an id from the event stream finds an entity already present in the scene. Exactly one of:
byName— the entity whose name the id produces, from a pattern embedding{id}(or a function). Use it when the scene names its entities after the ids the stream carries: it removes the need to collect and configure UUIDs entirely;byUuid— a fixedid → entity UUIDtable, for a known, closed population (the moving parts of one machine);resolve— a function, for anything else (a lookup service, a naming convention with exceptions, an id needing normalization).
Type Declaration
| Name | Type | Description |
|---|---|---|
linkage? | UUID[] | The linkage to find the entities under — the chain of scene references leading to them, empty (the default) for entities of the scene itself. A byUuid entry declaring its own linkage wins. |