pacc 3.13.1 → 4.0.0
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.
- package/README.md +66 -66
- package/package.json +1 -1
- package/src/attributes.mjs +52 -0
- package/src/common-attributes.mjs +29 -20
- package/src/module.mjs +2 -1
- package/src/multiple.mjs +1 -54
- package/types/attributes.d.mts +7 -0
- package/types/common-attributes.d.mts +8 -19
- package/types/module.d.mts +2 -1
- package/types/multiple.d.mts +0 -7
- /package/src/{attribute.mjs → settergetter.mjs} +0 -0
- /package/types/{attribute.d.mts → settergetter.d.mts} +0 -0
package/README.md
CHANGED
|
@@ -27,15 +27,10 @@ const result = getAttribute({ a: [0,{ b: 4 }]}, "a[1].b");
|
|
|
27
27
|
|
|
28
28
|
### Table of Contents
|
|
29
29
|
|
|
30
|
-
* [
|
|
31
|
-
* [tokens](#tokens-1)
|
|
30
|
+
* [prepareAttributesDefinitions](#prepareattributesdefinitions)
|
|
32
31
|
* [Parameters](#parameters)
|
|
33
|
-
* [
|
|
32
|
+
* [mergeAttributeDefinitions](#mergeattributedefinitions)
|
|
34
33
|
* [Parameters](#parameters-1)
|
|
35
|
-
* [getAttribute](#getattribute)
|
|
36
|
-
* [Parameters](#parameters-2)
|
|
37
|
-
* [getAttributeAndOperator](#getattributeandoperator)
|
|
38
|
-
* [Parameters](#parameters-3)
|
|
39
34
|
* [AttributeDefinition](#attributedefinition)
|
|
40
35
|
* [Properties](#properties)
|
|
41
36
|
* [default\_attribute](#default_attribute)
|
|
@@ -69,14 +64,19 @@ const result = getAttribute({ a: [0,{ b: 4 }]}, "a[1].b");
|
|
|
69
64
|
* [active\_attribute](#active_attribute)
|
|
70
65
|
* [language\_attribute](#language_attribute)
|
|
71
66
|
* [filter](#filter)
|
|
67
|
+
* [Parameters](#parameters-2)
|
|
68
|
+
* [setAttributes](#setattributes)
|
|
69
|
+
* [Parameters](#parameters-3)
|
|
70
|
+
* [getAttributes](#getattributes)
|
|
72
71
|
* [Parameters](#parameters-4)
|
|
73
|
-
* [
|
|
72
|
+
* [tokens](#tokens)
|
|
73
|
+
* [tokens](#tokens-1)
|
|
74
74
|
* [Parameters](#parameters-5)
|
|
75
|
-
* [
|
|
75
|
+
* [setAttribute](#setattribute)
|
|
76
76
|
* [Parameters](#parameters-6)
|
|
77
|
-
* [
|
|
77
|
+
* [getAttribute](#getattribute)
|
|
78
78
|
* [Parameters](#parameters-7)
|
|
79
|
-
* [
|
|
79
|
+
* [getAttributeAndOperator](#getattributeandoperator)
|
|
80
80
|
* [Parameters](#parameters-8)
|
|
81
81
|
* [lookup](#lookup)
|
|
82
82
|
* [Token](#token)
|
|
@@ -110,50 +110,27 @@ const result = getAttribute({ a: [0,{ b: 4 }]}, "a[1].b");
|
|
|
110
110
|
* [BAR](#bar)
|
|
111
111
|
* [DOUBLE\_BAR](#double_bar)
|
|
112
112
|
|
|
113
|
-
##
|
|
114
|
-
|
|
115
|
-
## tokens
|
|
116
|
-
|
|
117
|
-
Split property path into tokens
|
|
118
|
-
|
|
119
|
-
### Parameters
|
|
120
|
-
|
|
121
|
-
* `string` **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** 
|
|
122
|
-
|
|
123
|
-
## setAttribute
|
|
124
|
-
|
|
125
|
-
Set object attribute.
|
|
126
|
-
The name may be a property path like 'a.b.c'.
|
|
127
|
-
|
|
128
|
-
### Parameters
|
|
129
|
-
|
|
130
|
-
* `object` **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)** 
|
|
131
|
-
* `expression` **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** 
|
|
132
|
-
* `value` **any** 
|
|
133
|
-
|
|
134
|
-
## getAttribute
|
|
113
|
+
## prepareAttributesDefinitions
|
|
135
114
|
|
|
136
|
-
|
|
137
|
-
The name may be a property path like 'a.b.c' or a\[2]
|
|
115
|
+
Create attributes from its definition.
|
|
138
116
|
|
|
139
117
|
### Parameters
|
|
140
118
|
|
|
141
|
-
* `
|
|
142
|
-
* `
|
|
119
|
+
* `newDefinitions` **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)** 
|
|
120
|
+
* `presentDefinitions` **([Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object) | [undefined](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/undefined))** optional merg in attributes
|
|
143
121
|
|
|
144
|
-
Returns **
|
|
122
|
+
Returns **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)** attributes
|
|
145
123
|
|
|
146
|
-
##
|
|
124
|
+
## mergeAttributeDefinitions
|
|
147
125
|
|
|
148
|
-
|
|
149
|
-
The name may be a property path like 'a.b.c <='.
|
|
126
|
+
Merge attribute definitions.
|
|
150
127
|
|
|
151
128
|
### Parameters
|
|
152
129
|
|
|
153
|
-
* `
|
|
154
|
-
* `
|
|
130
|
+
* `dest` **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)** attribute definitions to be used also the merge target
|
|
131
|
+
* `atts` **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)?** attribute definitions to be used
|
|
155
132
|
|
|
156
|
-
Returns
|
|
133
|
+
Returns **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)** merged definitions (dest)
|
|
157
134
|
|
|
158
135
|
## AttributeDefinition
|
|
159
136
|
|
|
@@ -318,28 +295,6 @@ Generate filter function.
|
|
|
318
295
|
|
|
319
296
|
Returns **[Function](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Statements/function)** 
|
|
320
297
|
|
|
321
|
-
## prepareAttributesDefinitions
|
|
322
|
-
|
|
323
|
-
Create attributes from its definition.
|
|
324
|
-
|
|
325
|
-
### Parameters
|
|
326
|
-
|
|
327
|
-
* `newDefinitions` **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)** 
|
|
328
|
-
* `presentDefinitions` **([Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object) | [undefined](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/undefined))** optional merg in attributes
|
|
329
|
-
|
|
330
|
-
Returns **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)** attributes
|
|
331
|
-
|
|
332
|
-
## mergeAttributeDefinitions
|
|
333
|
-
|
|
334
|
-
Merge attribute definitions.
|
|
335
|
-
|
|
336
|
-
### Parameters
|
|
337
|
-
|
|
338
|
-
* `dest` **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)** attribute definitions to be used also the merge target
|
|
339
|
-
* `atts` **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)?** attribute definitions to be used
|
|
340
|
-
|
|
341
|
-
Returns **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)** merged definitions (dest)
|
|
342
|
-
|
|
343
298
|
## setAttributes
|
|
344
299
|
|
|
345
300
|
Copies attribute values from a source object into a destination object.
|
|
@@ -363,6 +318,51 @@ Retrive attribute values from an object.
|
|
|
363
318
|
|
|
364
319
|
Returns **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)** values
|
|
365
320
|
|
|
321
|
+
## tokens
|
|
322
|
+
|
|
323
|
+
## tokens
|
|
324
|
+
|
|
325
|
+
Split property path into tokens
|
|
326
|
+
|
|
327
|
+
### Parameters
|
|
328
|
+
|
|
329
|
+
* `string` **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** 
|
|
330
|
+
|
|
331
|
+
## setAttribute
|
|
332
|
+
|
|
333
|
+
Set object attribute.
|
|
334
|
+
The name may be a property path like 'a.b.c'.
|
|
335
|
+
|
|
336
|
+
### Parameters
|
|
337
|
+
|
|
338
|
+
* `object` **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)** 
|
|
339
|
+
* `expression` **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** 
|
|
340
|
+
* `value` **any** 
|
|
341
|
+
|
|
342
|
+
## getAttribute
|
|
343
|
+
|
|
344
|
+
Deliver attribute value.
|
|
345
|
+
The name may be a property path like 'a.b.c' or a\[2]
|
|
346
|
+
|
|
347
|
+
### Parameters
|
|
348
|
+
|
|
349
|
+
* `object` **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)** 
|
|
350
|
+
* `expression` **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** 
|
|
351
|
+
|
|
352
|
+
Returns **any** value associated with the given property name
|
|
353
|
+
|
|
354
|
+
## getAttributeAndOperator
|
|
355
|
+
|
|
356
|
+
Deliver attribute value and operator.
|
|
357
|
+
The name may be a property path like 'a.b.c <='.
|
|
358
|
+
|
|
359
|
+
### Parameters
|
|
360
|
+
|
|
361
|
+
* `object` **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)** 
|
|
362
|
+
* `expression` **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** 
|
|
363
|
+
|
|
364
|
+
Returns **\[any, [Token](#token)]** value associated with the given property name
|
|
365
|
+
|
|
366
366
|
## lookup
|
|
367
367
|
|
|
368
368
|
Token lookup
|
package/package.json
CHANGED
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
const types = {
|
|
2
|
+
base: { name: "base" },
|
|
3
|
+
string: { name: "string" },
|
|
4
|
+
number: { name: "number" },
|
|
5
|
+
integer: { name: "integer" },
|
|
6
|
+
"unsigned-integer": { name: "unsigned-integer" },
|
|
7
|
+
boolean: { name: "boolean" },
|
|
8
|
+
object: { name: "object" }
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* Create attributes from its definition.
|
|
13
|
+
* @param {Object} newDefinitions
|
|
14
|
+
* @param {Object|undefined} presentDefinitions optional merg in attributes
|
|
15
|
+
* @return {Object} attributes
|
|
16
|
+
*/
|
|
17
|
+
export function prepareAttributesDefinitions(newDefinitions, presentDefinitions) {
|
|
18
|
+
for (const [name, d] of Object.entries(newDefinitions)) {
|
|
19
|
+
if (d.attributes === undefined) {
|
|
20
|
+
d.type = types[d.type] || types.base;
|
|
21
|
+
}
|
|
22
|
+
else {
|
|
23
|
+
prepareAttributesDefinitions(d.attributes);
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
return mergeAttributeDefinitions(newDefinitions, presentDefinitions);
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Merge attribute definitions.
|
|
32
|
+
* @param {Object} dest attribute definitions to be used also the merge target
|
|
33
|
+
* @param {Object?} atts attribute definitions to be used
|
|
34
|
+
* @return {Object} merged definitions (dest)
|
|
35
|
+
*/
|
|
36
|
+
function mergeAttributeDefinitions(dest, atts) {
|
|
37
|
+
if (atts) {
|
|
38
|
+
for (const [name, ca] of Object.entries(atts)) {
|
|
39
|
+
if (ca.attributes !== undefined) {
|
|
40
|
+
const bn = dest[name];
|
|
41
|
+
|
|
42
|
+
if (bn !== undefined) {
|
|
43
|
+
Object.assign(ca.attributes, bn.attributes);
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
return Object.assign(dest, atts);
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
return dest;
|
|
52
|
+
}
|
|
@@ -41,7 +41,10 @@ export const name_attribute = {
|
|
|
41
41
|
/**
|
|
42
42
|
* @type {AttributeDefinition}
|
|
43
43
|
*/
|
|
44
|
-
export const email_attribute =
|
|
44
|
+
export const email_attribute = {
|
|
45
|
+
...default_attribute,
|
|
46
|
+
description: "email address"
|
|
47
|
+
};
|
|
45
48
|
|
|
46
49
|
/**
|
|
47
50
|
* The description of the object content.
|
|
@@ -56,7 +59,7 @@ export const description_attribute = {
|
|
|
56
59
|
/**
|
|
57
60
|
* @type {AttributeDefinition}
|
|
58
61
|
*/
|
|
59
|
-
export
|
|
62
|
+
export { default_attribute as type_attribute };
|
|
60
63
|
|
|
61
64
|
/**
|
|
62
65
|
* @type {AttributeDefinition}
|
|
@@ -69,22 +72,38 @@ export const state_attribute = {
|
|
|
69
72
|
/**
|
|
70
73
|
* @type {AttributeDefinition}
|
|
71
74
|
*/
|
|
72
|
-
export const
|
|
75
|
+
export const boolean_attribute_writeable_true = {
|
|
73
76
|
...default_attribute,
|
|
74
77
|
type: "boolean",
|
|
75
78
|
writable: true,
|
|
76
|
-
default:
|
|
79
|
+
default: true
|
|
77
80
|
};
|
|
78
81
|
|
|
79
82
|
/**
|
|
80
83
|
* @type {AttributeDefinition}
|
|
81
84
|
*/
|
|
82
|
-
export const
|
|
85
|
+
export const boolean_attribute_writeable_false = {
|
|
83
86
|
...default_attribute,
|
|
84
87
|
type: "boolean",
|
|
88
|
+
writable: true,
|
|
85
89
|
default: false
|
|
86
90
|
};
|
|
87
91
|
|
|
92
|
+
export { boolean_attribute_writeable_false as boolean_attribute };
|
|
93
|
+
|
|
94
|
+
/**
|
|
95
|
+
* @type {AttributeDefinition}
|
|
96
|
+
*/
|
|
97
|
+
export const boolean_attribute_false = {
|
|
98
|
+
...boolean_attribute_writeable_false,
|
|
99
|
+
writable: false
|
|
100
|
+
};
|
|
101
|
+
|
|
102
|
+
/**
|
|
103
|
+
* @type {AttributeDefinition}
|
|
104
|
+
*/
|
|
105
|
+
export { boolean_attribute_writeable_true as active_attribute };
|
|
106
|
+
|
|
88
107
|
/**
|
|
89
108
|
* @type {AttributeDefinition}
|
|
90
109
|
*/
|
|
@@ -171,12 +190,12 @@ export const integer_attribute = { ...default_attribute, type: "integer" };
|
|
|
171
190
|
/**
|
|
172
191
|
* @type {AttributeDefinition}
|
|
173
192
|
*/
|
|
174
|
-
export
|
|
193
|
+
export { integer_attribute as count_attribute };
|
|
175
194
|
|
|
176
195
|
/**
|
|
177
196
|
* @type {AttributeDefinition}
|
|
178
197
|
*/
|
|
179
|
-
export
|
|
198
|
+
export { integer_attribute as size_attribute };
|
|
180
199
|
|
|
181
200
|
/**
|
|
182
201
|
* @type {AttributeDefinition}
|
|
@@ -204,7 +223,7 @@ export const port_attribute = {
|
|
|
204
223
|
};
|
|
205
224
|
|
|
206
225
|
/**
|
|
207
|
-
* Unique id within
|
|
226
|
+
* Unique id within.
|
|
208
227
|
* @type {AttributeDefinition}
|
|
209
228
|
*/
|
|
210
229
|
export const id_attribute = {
|
|
@@ -214,7 +233,7 @@ export const id_attribute = {
|
|
|
214
233
|
};
|
|
215
234
|
|
|
216
235
|
/**
|
|
217
|
-
* The body text
|
|
236
|
+
* The body text.
|
|
218
237
|
* @type {AttributeDefinition}
|
|
219
238
|
*/
|
|
220
239
|
export const body_attribute = {
|
|
@@ -223,7 +242,7 @@ export const body_attribute = {
|
|
|
223
242
|
};
|
|
224
243
|
|
|
225
244
|
/**
|
|
226
|
-
* The one line description
|
|
245
|
+
* The one line description.
|
|
227
246
|
* @type {AttributeDefinition}
|
|
228
247
|
*/
|
|
229
248
|
export const title_attribute = {
|
|
@@ -254,16 +273,6 @@ export const timeout_attribute = {
|
|
|
254
273
|
writable: true
|
|
255
274
|
};
|
|
256
275
|
|
|
257
|
-
|
|
258
|
-
/**
|
|
259
|
-
* @type {AttributeDefinition}
|
|
260
|
-
*/
|
|
261
|
-
export const active_attribute = {
|
|
262
|
-
...boolean_attribute,
|
|
263
|
-
default: true,
|
|
264
|
-
writable: true
|
|
265
|
-
};
|
|
266
|
-
|
|
267
276
|
/**
|
|
268
277
|
* @type {AttributeDefinition}
|
|
269
278
|
*/
|
package/src/module.mjs
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
export * from "./tokens.mjs";
|
|
2
2
|
export * from "./filter.mjs";
|
|
3
3
|
export * from "./multiple.mjs";
|
|
4
|
+
export * from "./attributes.mjs";
|
|
4
5
|
export * from "./common-attributes.mjs";
|
|
5
6
|
export {
|
|
6
7
|
setAttribute,
|
|
7
8
|
getAttribute,
|
|
8
9
|
getAttributeAndOperator
|
|
9
|
-
} from "./
|
|
10
|
+
} from "./settergetter.mjs";
|
package/src/multiple.mjs
CHANGED
|
@@ -1,57 +1,4 @@
|
|
|
1
|
-
import { setAttribute, getAttribute } from "./
|
|
2
|
-
|
|
3
|
-
const types = {
|
|
4
|
-
base: { name: "base" },
|
|
5
|
-
string: { name: "string" },
|
|
6
|
-
number: { name: "number" },
|
|
7
|
-
integer: { name: "integer" },
|
|
8
|
-
"unsigned-integer": { name: "unsigned-integer" },
|
|
9
|
-
boolean: { name: "boolean" },
|
|
10
|
-
object: { name: "object" }
|
|
11
|
-
};
|
|
12
|
-
|
|
13
|
-
/**
|
|
14
|
-
* Create attributes from its definition.
|
|
15
|
-
* @param {Object} newDefinitions
|
|
16
|
-
* @param {Object|undefined} presentDefinitions optional merg in attributes
|
|
17
|
-
* @return {Object} attributes
|
|
18
|
-
*/
|
|
19
|
-
export function prepareAttributesDefinitions(newDefinitions, presentDefinitions) {
|
|
20
|
-
for (const [name, d] of Object.entries(newDefinitions)) {
|
|
21
|
-
if (d.attributes === undefined) {
|
|
22
|
-
d.type = types[d.type] || types.base;
|
|
23
|
-
}
|
|
24
|
-
else {
|
|
25
|
-
prepareAttributesDefinitions(d.attributes);
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
return mergeAttributeDefinitions(newDefinitions, presentDefinitions);
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
/**
|
|
33
|
-
* Merge attribute definitions.
|
|
34
|
-
* @param {Object} dest attribute definitions to be used also the merge target
|
|
35
|
-
* @param {Object?} atts attribute definitions to be used
|
|
36
|
-
* @return {Object} merged definitions (dest)
|
|
37
|
-
*/
|
|
38
|
-
function mergeAttributeDefinitions(dest, atts) {
|
|
39
|
-
if (atts) {
|
|
40
|
-
for (const [name, ca] of Object.entries(atts)) {
|
|
41
|
-
if (ca.attributes !== undefined) {
|
|
42
|
-
const bn = dest[name];
|
|
43
|
-
|
|
44
|
-
if (bn !== undefined) {
|
|
45
|
-
Object.assign(ca.attributes, bn.attributes);
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
return Object.assign(dest, atts);
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
return dest;
|
|
54
|
-
}
|
|
1
|
+
import { setAttribute, getAttribute } from "./settergetter.mjs";
|
|
55
2
|
|
|
56
3
|
/**
|
|
57
4
|
* Copies attribute values from a source object into a destination object.
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Create attributes from its definition.
|
|
3
|
+
* @param {Object} newDefinitions
|
|
4
|
+
* @param {Object|undefined} presentDefinitions optional merg in attributes
|
|
5
|
+
* @return {Object} attributes
|
|
6
|
+
*/
|
|
7
|
+
export function prepareAttributesDefinitions(newDefinitions: any, presentDefinitions: any | undefined): any;
|
|
@@ -36,19 +36,19 @@ export const description_attribute: AttributeDefinition;
|
|
|
36
36
|
/**
|
|
37
37
|
* @type {AttributeDefinition}
|
|
38
38
|
*/
|
|
39
|
-
export const
|
|
39
|
+
export const state_attribute: AttributeDefinition;
|
|
40
40
|
/**
|
|
41
41
|
* @type {AttributeDefinition}
|
|
42
42
|
*/
|
|
43
|
-
export const
|
|
43
|
+
export const boolean_attribute_writeable_true: AttributeDefinition;
|
|
44
44
|
/**
|
|
45
45
|
* @type {AttributeDefinition}
|
|
46
46
|
*/
|
|
47
|
-
export const
|
|
47
|
+
export const boolean_attribute_writeable_false: AttributeDefinition;
|
|
48
48
|
/**
|
|
49
49
|
* @type {AttributeDefinition}
|
|
50
50
|
*/
|
|
51
|
-
export const
|
|
51
|
+
export const boolean_attribute_false: AttributeDefinition;
|
|
52
52
|
/**
|
|
53
53
|
* @type {AttributeDefinition}
|
|
54
54
|
*/
|
|
@@ -89,14 +89,6 @@ export const public_key_attribute: AttributeDefinition;
|
|
|
89
89
|
* @type {AttributeDefinition}
|
|
90
90
|
*/
|
|
91
91
|
export const integer_attribute: AttributeDefinition;
|
|
92
|
-
/**
|
|
93
|
-
* @type {AttributeDefinition}
|
|
94
|
-
*/
|
|
95
|
-
export const count_attribute: AttributeDefinition;
|
|
96
|
-
/**
|
|
97
|
-
* @type {AttributeDefinition}
|
|
98
|
-
*/
|
|
99
|
-
export const size_attribute: AttributeDefinition;
|
|
100
92
|
/**
|
|
101
93
|
* @type {AttributeDefinition}
|
|
102
94
|
*/
|
|
@@ -110,17 +102,17 @@ export const hostname_attribute: AttributeDefinition;
|
|
|
110
102
|
*/
|
|
111
103
|
export const port_attribute: AttributeDefinition;
|
|
112
104
|
/**
|
|
113
|
-
* Unique id within
|
|
105
|
+
* Unique id within.
|
|
114
106
|
* @type {AttributeDefinition}
|
|
115
107
|
*/
|
|
116
108
|
export const id_attribute: AttributeDefinition;
|
|
117
109
|
/**
|
|
118
|
-
* The body text
|
|
110
|
+
* The body text.
|
|
119
111
|
* @type {AttributeDefinition}
|
|
120
112
|
*/
|
|
121
113
|
export const body_attribute: AttributeDefinition;
|
|
122
114
|
/**
|
|
123
|
-
* The one line description
|
|
115
|
+
* The one line description.
|
|
124
116
|
* @type {AttributeDefinition}
|
|
125
117
|
*/
|
|
126
118
|
export const title_attribute: AttributeDefinition;
|
|
@@ -134,10 +126,6 @@ export const priority_attribute: AttributeDefinition;
|
|
|
134
126
|
* @type {AttributeDefinition}
|
|
135
127
|
*/
|
|
136
128
|
export const timeout_attribute: AttributeDefinition;
|
|
137
|
-
/**
|
|
138
|
-
* @type {AttributeDefinition}
|
|
139
|
-
*/
|
|
140
|
-
export const active_attribute: AttributeDefinition;
|
|
141
129
|
/**
|
|
142
130
|
* @type {AttributeDefinition}
|
|
143
131
|
*/
|
|
@@ -181,3 +169,4 @@ export type AttributeDefinition = {
|
|
|
181
169
|
*/
|
|
182
170
|
env?: string[] | string;
|
|
183
171
|
};
|
|
172
|
+
export { default_attribute as type_attribute, boolean_attribute_writeable_false as boolean_attribute, boolean_attribute_writeable_true as active_attribute, integer_attribute as count_attribute, integer_attribute as size_attribute };
|
package/types/module.d.mts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export * from "./tokens.mjs";
|
|
2
2
|
export * from "./filter.mjs";
|
|
3
3
|
export * from "./multiple.mjs";
|
|
4
|
+
export * from "./attributes.mjs";
|
|
4
5
|
export * from "./common-attributes.mjs";
|
|
5
|
-
export { setAttribute, getAttribute, getAttributeAndOperator } from "./
|
|
6
|
+
export { setAttribute, getAttribute, getAttributeAndOperator } from "./settergetter.mjs";
|
package/types/multiple.d.mts
CHANGED
|
@@ -1,10 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Create attributes from its definition.
|
|
3
|
-
* @param {Object} newDefinitions
|
|
4
|
-
* @param {Object|undefined} presentDefinitions optional merg in attributes
|
|
5
|
-
* @return {Object} attributes
|
|
6
|
-
*/
|
|
7
|
-
export function prepareAttributesDefinitions(newDefinitions: any, presentDefinitions: any | undefined): any;
|
|
8
1
|
/**
|
|
9
2
|
* Copies attribute values from a source object into a destination object.
|
|
10
3
|
* @param {Object} object target object to be modified
|
|
File without changes
|
|
File without changes
|