You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It is often useful to be able to retrieve all used supervision instances.
We currently have:
/** * Returns the used supervision LN instances for a given service type. * * @param doc - SCL document. * @param serviceType - either GOOSE or SMV. * @returns - array of Elements of supervision LN instances. */exportfunctiongetUsedSupervisionInstances(doc: Document,serviceType: string): Element[]{if(!doc)return[];constsupervisionType=serviceType==='GOOSE' ? 'LGOS' : 'LSVS';constrefSelector=supervisionType==='LGOS' ? 'DOI[name="GoCBRef"]' : 'DOI[name="SvCBRef"]';constsupervisionInstances=Array.from(doc!.querySelectorAll(`:root > IED > AccessPoint > Server > LDevice > LN[lnClass="${supervisionType}"]>${refSelector}>DAI[name="setSrcRef"]>Val`)).filter(val=>val.textContent!=='').map(val=>val.closest('LN')!);returnsupervisionInstances;}
The text was updated successfully, but these errors were encountered:
It is often useful to be able to retrieve all used supervision instances.
We currently have:
The text was updated successfully, but these errors were encountered: