@hello.nrfcloud.com/proto-map 10.0.1 → 10.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -682,7 +682,7 @@ var _obj;
682
682
  0: {
683
683
  ResourceID: 0,
684
684
  Name: "Update interval",
685
- Mandatory: false,
685
+ Mandatory: true,
686
686
  Type: ResourceType.Integer,
687
687
  Description: "The update interval in seconds. Examples: 10, 3600.",
688
688
  RangeEnumeration: {
@@ -697,7 +697,7 @@ var _obj;
697
697
  */ 1: {
698
698
  ResourceID: 1,
699
699
  Name: "GNSS enabled",
700
- Mandatory: false,
700
+ Mandatory: true,
701
701
  Type: ResourceType.Boolean,
702
702
  Description: "Whether to enabled the device's GNSS receiver."
703
703
  },
@@ -1,4 +1,4 @@
1
- import { TimeResource, NumberResource, OptionalResource, BooleanResource, validateInstance } from "../validation.js";
1
+ import { NumberResource, BooleanResource, TimeResource, validateInstance } from "../validation.js";
2
2
  import { LwM2MObjectID } from "../LwM2MObjectID.js";
3
3
  /**
4
4
  * Validate Application Configuration (14301)
@@ -6,8 +6,8 @@ import { LwM2MObjectID } from "../LwM2MObjectID.js";
6
6
  * Ensures the given object is an LwM2M object according to the schema 14301.xml.
7
7
  */ export var validate14301 = function(o) {
8
8
  return validateInstance(LwM2MObjectID.ApplicationConfiguration_14301, "1.0", {
9
- 99: TimeResource,
10
- 0: OptionalResource(NumberResource),
11
- 1: OptionalResource(BooleanResource)
9
+ 0: NumberResource,
10
+ 1: BooleanResource,
11
+ 99: TimeResource
12
12
  })(o);
13
13
  };
package/lwm2m/14301.xml CHANGED
@@ -12,7 +12,7 @@
12
12
  <Name>Update interval</Name>
13
13
  <Operations>RW</Operations>
14
14
  <MultipleInstances>Single</MultipleInstances>
15
- <Mandatory>Optional</Mandatory>
15
+ <Mandatory>Mandatory</Mandatory>
16
16
  <Type>Integer</Type>
17
17
  <RangeEnumeration>0..31622400</RangeEnumeration>
18
18
  <Units/>
@@ -22,7 +22,7 @@
22
22
  <Name>GNSS enabled</Name>
23
23
  <Operations>RW</Operations>
24
24
  <MultipleInstances>Single</MultipleInstances>
25
- <Mandatory>Optional</Mandatory>
25
+ <Mandatory>Mandatory</Mandatory>
26
26
  <Type>Boolean</Type>
27
27
  <RangeEnumeration/>
28
28
  <Units/>
@@ -325,12 +325,12 @@ export const definitions: Record<LwM2MObjectID, LWM2MObjectInfo> = { /**
325
325
  * Minimum: 0
326
326
  * Maximum: 31622400
327
327
  */
328
- 0: { ResourceID: 0, Name: "Update interval", Mandatory: false, Type: ResourceType.Integer, Description: "The update interval in seconds. Examples: 10, 3600.", RangeEnumeration: { min: 0, max: 31622400 } }, /**
328
+ 0: { ResourceID: 0, Name: "Update interval", Mandatory: true, Type: ResourceType.Integer, Description: "The update interval in seconds. Examples: 10, 3600.", RangeEnumeration: { min: 0, max: 31622400 } }, /**
329
329
  * GNSS enabled (Boolean)
330
330
  *
331
331
  * Whether to enabled the device's GNSS receiver.
332
332
  */
333
- 1: { ResourceID: 1, Name: "GNSS enabled", Mandatory: false, Type: ResourceType.Boolean, Description: "Whether to enabled the device's GNSS receiver." }, /**
333
+ 1: { ResourceID: 1, Name: "GNSS enabled", Mandatory: true, Type: ResourceType.Boolean, Description: "Whether to enabled the device's GNSS receiver." }, /**
334
334
  * Timestamp (Time)
335
335
  *
336
336
  * The timestamp of when the configuration was updated.
@@ -9,12 +9,6 @@ export type ApplicationConfiguration_14301 = LwM2MObject<{
9
9
  ObjectID: LwM2MObjectID.ApplicationConfiguration_14301;
10
10
  ObjectVersion: "1.0";
11
11
  Resources: {
12
- /**
13
- * Timestamp
14
- *
15
- * The timestamp of when the configuration was updated.
16
- */
17
- 99: number;
18
12
  /**
19
13
  * Update interval
20
14
  *
@@ -23,12 +17,18 @@ export type ApplicationConfiguration_14301 = LwM2MObject<{
23
17
  * Minimum: 0
24
18
  * Maximum: 31622400
25
19
  */
26
- 0?: number;
20
+ 0: number;
27
21
  /**
28
22
  * GNSS enabled
29
23
  *
30
24
  * Whether to enabled the device's GNSS receiver.
31
25
  */
32
- 1?: boolean;
26
+ 1: boolean;
27
+ /**
28
+ * Timestamp
29
+ *
30
+ * The timestamp of when the configuration was updated.
31
+ */
32
+ 99: number;
33
33
  };
34
34
  }>;
@@ -1,5 +1,5 @@
1
1
  import type { LwM2MObjectInstance } from "../LwM2MObjectInstance.js";
2
- import { TimeResource, NumberResource, OptionalResource, BooleanResource, validateInstance } from "../validation.js";
2
+ import { NumberResource, BooleanResource, TimeResource, validateInstance } from "../validation.js";
3
3
  import type { ApplicationConfiguration_14301 } from "../objects.js";
4
4
  import { LwM2MObjectID } from "../LwM2MObjectID.js";
5
5
  /**
@@ -11,4 +11,4 @@ export const validate14301 = (o: unknown): {
11
11
  error: Error;
12
12
  } | {
13
13
  object: LwM2MObjectInstance<ApplicationConfiguration_14301>;
14
- } => validateInstance<ApplicationConfiguration_14301>(LwM2MObjectID.ApplicationConfiguration_14301, "1.0", { 99: TimeResource, 0: OptionalResource(NumberResource), 1: OptionalResource(BooleanResource) })(o);
14
+ } => validateInstance<ApplicationConfiguration_14301>(LwM2MObjectID.ApplicationConfiguration_14301, "1.0", { 0: NumberResource, 1: BooleanResource, 99: TimeResource })(o);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hello.nrfcloud.com/proto-map",
3
- "version": "10.0.1",
3
+ "version": "10.0.2",
4
4
  "description": "Documents the communication protocol between devices, the hello.nrfcloud.com/map backend and web application",
5
5
  "type": "module",
6
6
  "exports": {