Class: EnvironmentDescriptor
Defined in: environment.ts:15
The platform environment a service is running in: a name plus the capability
strings the host offers, such as "dom" or "render-loop". Configuration
profiles gate on it, so a service can register differently on a browser page
and in a headless test.
Not to be confused with EnvironmentSpec from
@realitycollective/webxr-environment, which describes the visual
environment - sky, fog and lighting. The two are unrelated, and an app can
hold both at once: this one answers "what can the host do", that one answers
"what does the world look like".
Implements
Constructors
Constructor
new EnvironmentDescriptor(name: string, capabilities?: Iterable<string>): EnvironmentDescriptor;
Defined in: environment.ts:18
Parameters
| Parameter | Type | Default value |
|---|---|---|
name | string | undefined |
capabilities | Iterable<string> | [] |
Returns
EnvironmentDescriptor
Properties
| Property | Modifier | Type | Defined in |
|---|---|---|---|
capabilities | readonly | ReadonlySet<string> | environment.ts:16 |
name | readonly | string | environment.ts:18 |
Methods
hasCapability()
hasCapability(capability: string): boolean;
Defined in: environment.ts:22
Parameters
| Parameter | Type |
|---|---|
capability | string |
Returns
boolean