added #runOnInstance and #runAtHour

This commit is contained in:
zadam
2021-04-08 21:22:47 +02:00
parent 052f584bf4
commit 9c679aef20
6 changed files with 58 additions and 15 deletions

View File

@@ -303,6 +303,14 @@ class Note extends Entity {
return this.getAttributes(LABEL, name);
}
/**
* @param {string} [name] - label name to filter
* @returns {string[]} all note's label values, including inherited ones
*/
getLabelValues(name) {
return this.getLabels(name).map(l => l.value);
}
/**
* @param {string} [name] - label name to filter
* @returns {Attribute[]} all note's labels (attributes with type label), excluding inherited ones
@@ -311,6 +319,14 @@ class Note extends Entity {
return this.getOwnedAttributes(LABEL, name);
}
/**
* @param {string} [name] - label name to filter
* @returns {string[]} all note's label values, excluding inherited ones
*/
getOwnedLabelValues(name) {
return this.getOwnedAttributes(LABEL, name).map(l => l.value);
}
/**
* @param {string} [name] - relation name to filter
* @returns {Attribute[]} all note's relations (attributes with type relation), including inherited ones