Skip to content

Commit

Permalink
docs: update typed documentation and API report
Browse files Browse the repository at this point in the history
  • Loading branch information
AlCalzone committed May 6, 2024
1 parent f1eec7c commit 37c30ed
Show file tree
Hide file tree
Showing 10 changed files with 969 additions and 194 deletions.
4 changes: 0 additions & 4 deletions docs/api/config-manager.md
Original file line number Diff line number Diff line change
Expand Up @@ -413,8 +413,6 @@ interface GenericDeviceClass {
readonly key: number;
readonly label: string;
readonly requiresSecurity?: boolean;
readonly supportedCCs: readonly CommandClasses[];
readonly controlledCCs: readonly CommandClasses[];
readonly maySupportBasicCC: boolean;
readonly specific: ReadonlyMap<number, SpecificDeviceClass>;
}
Expand All @@ -428,8 +426,6 @@ interface SpecificDeviceClass {
readonly label: string;
readonly zwavePlusDeviceType?: string;
readonly requiresSecurity?: boolean;
readonly supportedCCs: readonly CommandClasses[];
readonly controlledCCs: readonly CommandClasses[];
readonly maySupportBasicCC: boolean;
}
```
Expand Down
2 changes: 1 addition & 1 deletion docs/api/controller.md
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ interface LifelineRoutes {
```ts
interface RouteStatistics {
/** The protocol and used data rate for this route */
protocolDataRate: ProtocolDataRate;
protocolDataRate?: ProtocolDataRate;
/** Which nodes are repeaters for this route */
repeaters: number[];

Expand Down
10 changes: 2 additions & 8 deletions docs/api/node.md
Original file line number Diff line number Diff line change
Expand Up @@ -884,8 +884,6 @@ interface DeviceClass {
readonly basic: BasicDeviceClass;
readonly generic: GenericDeviceClass;
readonly specific: SpecificDeviceClass;
readonly mandatorySupportedCCs: readonly CommandClasses[];
readonly mandatoryControlledCCs: readonly CommandClasses[];
}
```

Expand All @@ -905,8 +903,6 @@ interface GenericDeviceClass {
readonly key: number;
readonly label: string;
readonly requiresSecurity?: boolean;
readonly supportedCCs: readonly CommandClasses[];
readonly controlledCCs: readonly CommandClasses[];
readonly maySupportBasicCC: boolean;
readonly specific: ReadonlyMap<number, SpecificDeviceClass>;
}
Expand All @@ -920,8 +916,6 @@ interface SpecificDeviceClass {
readonly label: string;
readonly zwavePlusDeviceType?: string;
readonly requiresSecurity?: boolean;
readonly supportedCCs: readonly CommandClasses[];
readonly controlledCCs: readonly CommandClasses[];
readonly maySupportBasicCC: boolean;
}
```
Expand All @@ -946,7 +940,7 @@ If the `Z-Wave+` Command Class is supported, this returns the `Z-Wave+` node typ

```ts
enum ZWavePlusNodeType {
Node = 0,
Node = 0, // ZWave+ Node
IPGateway = 2,
}
```
Expand Down Expand Up @@ -1559,7 +1553,7 @@ interface NodeStatistics {
```ts
interface RouteStatistics {
/** The protocol and used data rate for this route */
protocolDataRate: ProtocolDataRate;
protocolDataRate?: ProtocolDataRate;
/** Which nodes are repeaters for this route */
repeaters: number[];

Expand Down
9 changes: 8 additions & 1 deletion docs/api/zniffer.md
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,10 @@ A valid frame can either be a Z-Wave frame or a Z-Wave Long Range frame...
<!-- #import Frame from "zwave-js" -->

```ts
type Frame = ZWaveFrame | LongRangeFrame;
type Frame =
| ZWaveFrame
| LongRangeFrame
| BeamFrame;
```

...both of which have several subtypes:
Expand Down Expand Up @@ -323,6 +326,8 @@ enum ZWaveFrameType {
ExplorerNormal,
ExplorerSearchResult,
ExplorerInclusionRequest,
BeamStart,
BeamStop,
}
```

Expand All @@ -332,6 +337,8 @@ enum ZWaveFrameType {
enum LongRangeFrameType {
Singlecast,
Ack,
BeamStart,
BeamStop,
}
```

Expand Down
41 changes: 21 additions & 20 deletions packages/cc/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -7926,9 +7926,9 @@ export enum HumidityControlSetpointType {
// (undocumented)
"De-humidifier" = 2,
// (undocumented)
"N/A" = 0,
"N/A" = 0,// CC v1
// (undocumented)
"Auto" = 3,
"Auto" = 3,// CC v1
// (undocumented)
"Humidifier" = 1
}
Expand Down Expand Up @@ -10195,21 +10195,21 @@ export function isTransportServiceEncapsulation(command: CommandClass): command
// @public (undocumented)
export enum KEXFailType {
// (undocumented)
BootstrappingCanceled = 6,
BootstrappingCanceled = 6,// KEX_KEY
// (undocumented)
Decrypt = 5,
Decrypt = 5,// KEX_SCHEME
// (undocumented)
DifferentKey = 10,
DifferentKey = 10,// KEX_CURVES
// (undocumented)
KeyNotGranted = 8,
// (undocumented)
NoKeyMatch = 1,
NoKeyMatch = 1,// CANCEL
// (undocumented)
NoSupportedCurve = 3,
NoSupportedCurve = 3,// AUTH
// (undocumented)
NoSupportedScheme = 2,
NoSupportedScheme = 2,// GET
// (undocumented)
NoVerify = 9,
NoVerify = 9,// VERIFY
// (undocumented)
WrongSecurityLevel = 7
}
Expand Down Expand Up @@ -15453,6 +15453,7 @@ export class Security2CCMessageEncapsulation extends Security2CC {
extensions: Security2Extension[];
// (undocumented)
getMulticastGroupId(): number | undefined;
getSenderEI(): Buffer | undefined;
// (undocumented)
hasMOSExtension(): boolean;
// (undocumented)
Expand Down Expand Up @@ -17676,25 +17677,25 @@ export enum ThermostatSetpointType {
// (undocumented)
"Auto Changeover" = 10,
// (undocumented)
"Away Cooling" = 14,
"Away Cooling" = 14,// CC v1
// (undocumented)
"Away Heating" = 13,
"Away Heating" = 13,// CC v1
// (undocumented)
"Dry Air" = 8,
"Dry Air" = 8,// CC v1
// (undocumented)
"Energy Save Cooling" = 12,
"Energy Save Cooling" = 12,// CC v1
// (undocumented)
"Energy Save Heating" = 11,
"Energy Save Heating" = 11,// CC v1
// (undocumented)
"Full Power" = 15,
"Full Power" = 15,// CC v1
// (undocumented)
"Moist Air" = 9,
"Moist Air" = 9,// CC v2
// (undocumented)
"N/A" = 0,
"N/A" = 0,// CC v2
// (undocumented)
"Cooling" = 2,
"Cooling" = 2,// CC v2
// (undocumented)
"Furnace" = 7,
"Furnace" = 7,// CC v3
// (undocumented)
"Heating" = 1
}
Expand Down Expand Up @@ -20525,7 +20526,7 @@ export enum ZWavePlusCommand {
// @public (undocumented)
export enum ZWavePlusNodeType {
// (undocumented)
IPGateway = 2,
IPGateway = 2,// ZWave+ Node
// (undocumented)
Node = 0
}
Expand Down
32 changes: 18 additions & 14 deletions packages/config/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,18 @@ export interface BasicDeviceClass {
// @public (undocumented)
export type BasicDeviceClassMap = ReadonlyMap<number, string>;

// Warning: (ae-forgotten-export) The symbol "basicReportMappings" needs to be exported by the entry point index.d.ts
// Warning: (ae-missing-release-tag) "BasicReportMapping" is part of the package's API, but it is missing a release tag (@alpha, @beta, @public, or @internal)
//
// @public
export type BasicReportMapping = typeof basicReportMappings[number];

// Warning: (ae-forgotten-export) The symbol "basicSetMappings" needs to be exported by the entry point index.d.ts
// Warning: (ae-missing-release-tag) "BasicSetMapping" is part of the package's API, but it is missing a release tag (@alpha, @beta, @public, or @internal)
//
// @public
export type BasicSetMapping = typeof basicSetMappings[number];

// Warning: (ae-missing-release-tag) "CompatAddCC" is part of the package's API, but it is missing a release tag (@alpha, @beta, @public, or @internal)
//
// @public (undocumented)
Expand Down Expand Up @@ -142,16 +154,12 @@ export class ConditionalCompatConfig implements ConditionalItem<CompatConfig> {
// (undocumented)
readonly disableAutoRefresh?: boolean;
// (undocumented)
readonly disableBasicMapping?: boolean;
// (undocumented)
readonly disableCallbackFunctionTypeCheck?: number[];
// (undocumented)
readonly disableStrictEntryControlDataValidation?: boolean;
// (undocumented)
readonly disableStrictMeasurementValidation?: boolean;
// (undocumented)
readonly enableBasicSetMapping?: boolean;
// (undocumented)
evaluateCondition(deviceId?: DeviceID): CompatConfig | undefined;
// (undocumented)
readonly forceNotificationIdleReset?: boolean;
Expand All @@ -160,6 +168,10 @@ export class ConditionalCompatConfig implements ConditionalItem<CompatConfig> {
// (undocumented)
readonly manualValueRefreshDelayMs?: number;
// (undocumented)
readonly mapBasicReport?: BasicReportMapping;
// (undocumented)
readonly mapBasicSet?: BasicSetMapping;
// (undocumented)
readonly mapRootReportsToEndpoint?: number;
// (undocumented)
readonly overrideFloatEncoding?: {
Expand Down Expand Up @@ -189,8 +201,6 @@ export class ConditionalCompatConfig implements ConditionalItem<CompatConfig> {
// (undocumented)
readonly skipConfigurationNameQuery?: boolean;
// (undocumented)
readonly treatBasicSetAsEvent?: boolean;
// (undocumented)
readonly treatDestinationEndpointAsSource?: boolean;
// (undocumented)
readonly treatMultilevelSwitchSetAsEvent?: boolean;
Expand Down Expand Up @@ -663,8 +673,6 @@ export interface FulltextDeviceConfigIndexEntry {
export class GenericDeviceClass {
constructor(key: number, definition: JSONObject);
// (undocumented)
readonly controlledCCs: readonly CommandClasses[];
// (undocumented)
readonly key: number;
// (undocumented)
readonly label: string;
Expand All @@ -674,8 +682,6 @@ export class GenericDeviceClass {
readonly requiresSecurity?: boolean;
// (undocumented)
readonly specific: ReadonlyMap<number, SpecificDeviceClass>;
// (undocumented)
readonly supportedCCs: readonly CommandClasses[];
}

// Warning: (ae-missing-release-tag) "GenericDeviceClassMap" is part of the package's API, but it is missing a release tag (@alpha, @beta, @public, or @internal)
Expand Down Expand Up @@ -847,6 +853,8 @@ export class NotificationParameterWithDuration {
export class NotificationParameterWithEnum {
constructor(definition: JSONObject);
// (undocumented)
readonly default?: number;
// (undocumented)
readonly values: ReadonlyMap<number, string>;
}

Expand Down Expand Up @@ -971,8 +979,6 @@ export type SensorTypeMap = ReadonlyMap<number, SensorType>;
export class SpecificDeviceClass {
constructor(key: number, definition: JSONObject, generic: GenericDeviceClass);
// (undocumented)
readonly controlledCCs: readonly CommandClasses[];
// (undocumented)
readonly key: number;
// (undocumented)
readonly label: string;
Expand All @@ -981,8 +987,6 @@ export class SpecificDeviceClass {
// (undocumented)
readonly requiresSecurity?: boolean;
// (undocumented)
readonly supportedCCs: readonly CommandClasses[];
// (undocumented)
readonly zwavePlusDeviceType?: string;
}

Expand Down
Loading

0 comments on commit 37c30ed

Please sign in to comment.