add yxml.forEach method - closes #421

This commit is contained in:
Kevin Jahns 2022-04-23 15:13:26 +02:00
parent 14c14de21e
commit 1c9c97ffe6

View File

@ -404,6 +404,15 @@ export class YXmlFragment extends AbstractType {
return typeListSlice(this, start, end)
}
/**
* Executes a provided function on once on overy child element.
*
* @param {function(YXmlElement|YXmlText,number, typeof this):void} f A function to execute on every element of this YArray.
*/
forEach (f) {
typeListForEach(this, f)
}
/**
* Transform the properties of this type to binary and write it to an
* BinaryEncoder.