import { IToXmlOptions } from './options'; import { IElement } from './util'; import { Value } from './value'; /** * Plist object. */ export declare class Plist { /** * Default XML declaration. */ static readonly XML_DECLARATION = ""; /** * Default XML doctype. */ static readonly XML_DOCTYPE = ""; /** * XML declaration. */ xmlDeclaration: string; /** * XML doctype. */ xmlDoctype: string; /** * Value element. */ value: Value | null; /** * Plist constructor. * * @param value The value. */ constructor(value?: Value | null); /** * Get value or throw if null. * * @returns The value. */ getValue(): Value; /** * Cast to specific type or null. * * @param Type Type constructor. * @returns The object or null. */ valueCastTo(Type: T): T['prototype'] | null; /** * Cast to specific type or throw. * * @param Type Type constructor. * @returns The object. */ valueCastAs(Type: T): T['prototype']; /** * Decode document from string. * * @param xml XML string. */ fromXml(xml: string): void; /** * Decode document from element. * * @param element XML element. * @param declaration XML declaration. * @param doctype XML doctype. */ fromXmlElement(element: Readonly, declaration?: string | null, doctype?: string | null): void; /** * Decode child element from XML element. * * @param element XML element. * @returns Value element. */ childFromXmlElement(element: IElement): Value; /** * Encode documents to string. * * @param options Options object. * @returns XML string. */ toXml(options?: Readonly | null): string; }