pmcf 1.51.0 → 1.52.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/package.json +1 -1
- package/src/host.mjs +8 -1
- package/types/host.d.mts +1 -0
package/package.json
CHANGED
package/src/host.mjs
CHANGED
|
@@ -129,6 +129,10 @@ export class Host extends Base {
|
|
|
129
129
|
return this.#vendor || this.extends.find(e => e.vendor)?.vendor;
|
|
130
130
|
}
|
|
131
131
|
|
|
132
|
+
get isTemplate() {
|
|
133
|
+
return this.isModel || this.name.match(/services\//); // TODO
|
|
134
|
+
}
|
|
135
|
+
|
|
132
136
|
get isModel() {
|
|
133
137
|
return this.#vendor || this.#chassis ? true : false;
|
|
134
138
|
}
|
|
@@ -266,7 +270,10 @@ export class Host extends Base {
|
|
|
266
270
|
|
|
267
271
|
set networkInterfaces(networkInterface) {
|
|
268
272
|
this.#networkInterfaces.set(networkInterface.name, networkInterface);
|
|
269
|
-
|
|
273
|
+
|
|
274
|
+
if (!this.isTemplate) {
|
|
275
|
+
networkInterface.network?.addObject(this);
|
|
276
|
+
}
|
|
270
277
|
}
|
|
271
278
|
|
|
272
279
|
*networkAddresses() {
|
package/types/host.d.mts
CHANGED