UNPKG

isoxml

Version:

JavaScript library to parse and generate ISOXML (ISO11783-10) files

37 lines (36 loc) 1.25 kB
import { TAGS } from './constants'; import { ISOXMLManager } from '../ISOXMLManager'; import { XMLElement } from '../types'; import { DeviceObjectReference } from './DeviceObjectReference'; import { Entity, EntityConstructor } from '../types'; export declare enum DeviceElementDeviceElementTypeEnum { Device = "1", Function = "2", Bin = "3", Section = "4", Unit = "5", Connector = "6", Navigation = "7" } export type DeviceElementAttributes = { DeviceElementObjectId: number; DeviceElementType: DeviceElementDeviceElementTypeEnum; DeviceElementDesignator?: string; DeviceElementNumber: number; ParentObjectId: number; DeviceObjectReference?: DeviceObjectReference[]; ProprietaryAttributes?: { [name: string]: string; }; ProprietaryTags?: { [tag: string]: XMLElement[]; }; }; export declare class DeviceElement implements Entity { attributes: DeviceElementAttributes; isoxmlManager: ISOXMLManager; tag: TAGS; constructor(attributes: DeviceElementAttributes, isoxmlManager: ISOXMLManager); static fromXML(xml: XMLElement, isoxmlManager: ISOXMLManager, internalId?: string, targetClass?: EntityConstructor): Promise<Entity>; toXML(): XMLElement; }