Table of Contents

Variable: createPartOf

const createPartOf: (attributes: {
  relation?: relations;
} & {
[qualifiedName: `${string}:${string}`]: string | undefined;
}, content: 
  | (
  | string
  | {
  kind: "comment";
  value: string;
}
  | {
  kind: "instruction";
  target: string;
  value: string;
}
  | entity_2)[]
  | partOf$Children) => partOf & {
  all: (parent?: {
     attributes: Record<string, string | undefined> & {
      [qualifiedName: `${string}:${string}`]: string | undefined;
     };
     content: (
        | string
        | {
        kind: "comment";
        value: string;
      }
        | {
        kind: "instruction";
        target: string;
        value: string;
      }
        | {
        attributes: Record<string, ... | ...> & {
         [qualifiedName: `${(...)}:${(...)}`]: ... | ...;
        };
        content: (string | XmlComment | XmlInstruction | GenericElement)[];
        name: string;
        namespaces?: Record<string, string>;
        namespaceURI: string;
        prefix?: string;
     })[];
     name: string;
     namespaces?: Record<string, string>;
     namespaceURI: string;
     prefix?: string;
  }) => partOf[];
  descendants: (parent?: {
     attributes: Record<string, string | undefined> & {
      [qualifiedName: `${string}:${string}`]: string | undefined;
     };
     content: (
        | string
        | {
        kind: "comment";
        value: string;
      }
        | {
        kind: "instruction";
        target: string;
        value: string;
      }
        | {
        attributes: Record<string, ... | ...> & {
         [qualifiedName: `${(...)}:${(...)}`]: ... | ...;
        };
        content: (string | XmlComment | XmlInstruction | GenericElement)[];
        name: string;
        namespaces?: Record<string, string>;
        namespaceURI: string;
        prefix?: string;
     })[];
     name: string;
     namespaces?: Record<string, string>;
     namespaceURI: string;
     prefix?: string;
  }) => partOf[];
  elementName: string;
  from: (parent?: {
     attributes: Record<string, string | undefined> & {
      [qualifiedName: `${string}:${string}`]: string | undefined;
     };
     content: (
        | string
        | {
        kind: "comment";
        value: string;
      }
        | {
        kind: "instruction";
        target: string;
        value: string;
      }
        | {
        attributes: Record<string, ... | ...> & {
         [qualifiedName: `${(...)}:${(...)}`]: ... | ...;
        };
        content: (string | XmlComment | XmlInstruction | GenericElement)[];
        name: string;
        namespaces?: Record<string, string>;
        namespaceURI: string;
        prefix?: string;
     })[];
     name: string;
     namespaces?: Record<string, string>;
     namespaceURI: string;
     prefix?: string;
  }) => partOf | undefined;
  is: (element?: {
     attributes: Record<string, string | undefined> & {
      [qualifiedName: `${string}:${string}`]: string | undefined;
     };
     content: (
        | string
        | {
        kind: "comment";
        value: string;
      }
        | {
        kind: "instruction";
        target: string;
        value: string;
      }
        | {
        attributes: Record<string, ... | ...> & {
         [qualifiedName: `${(...)}:${(...)}`]: ... | ...;
        };
        content: (string | XmlComment | XmlInstruction | GenericElement)[];
        name: string;
        namespaces?: Record<string, string>;
        namespaceURI: string;
        prefix?: string;
     })[];
     name: string;
     namespaces?: Record<string, string>;
     namespaceURI: string;
     prefix?: string;
  }) => element is partOf;
  namespaceURI: string;
} & {
  defaults: Partial<{
     relation?: relations;
   } & {
   [qualifiedName: `${string}:${string}`]: string | undefined;
  }>;
  read(element?: {
     attributes: Record<string, string | undefined> & {
      [qualifiedName: `${string}:${string}`]: string | undefined;
     };
     content: (
        | string
        | {
        kind: "comment";
        value: string;
      }
        | {
        kind: "instruction";
        target: string;
        value: string;
      }
        | {
        attributes: Record<string, string | undefined> & {
         [qualifiedName: `${string}:${string}`]: string | undefined;
        };
        content: (string | XmlComment | XmlInstruction | GenericElement)[];
        name: string;
        namespaces?: Record<string, string>;
        namespaceURI: string;
        prefix?: string;
     })[];
     name: string;
     namespaces?: Record<string, string>;
     namespaceURI: string;
     prefix?: string;
   }): 
     | {
     attributes: {
        relation?: relations;
      } & {
      [qualifiedName: `${string}:${string}`]: string | undefined;
     };
     children: {
        entity: entity_2 | undefined;
     };
   }
    | undefined;
  update(element: partOf, attributes: Partial<E["attributes"]>, changes: Partial<F>): partOf;
};

Create/read the XML partOf element. Named children follow XSD order and occurrence constraints.

Type Declaration

all

all: (parent?: {
  attributes: Record<string, string | undefined> & {
   [qualifiedName: `${string}:${string}`]: string | undefined;
  };
  content: (
     | string
     | {
     kind: "comment";
     value: string;
   }
     | {
     kind: "instruction";
     target: string;
     value: string;
   }
     | {
     attributes: Record<string, ... | ...> & {
      [qualifiedName: `${(...)}:${(...)}`]: ... | ...;
     };
     content: (string | XmlComment | XmlInstruction | GenericElement)[];
     name: string;
     namespaces?: Record<string, string>;
     namespaceURI: string;
     prefix?: string;
  })[];
  name: string;
  namespaces?: Record<string, string>;
  namespaceURI: string;
  prefix?: string;
}) => partOf[];

Parameters

parent?
attributes

Record<string, string | undefined> & { [qualifiedName: `${string}:${string}`]: string | undefined; }

content

( | string | { kind: "comment"; value: string; } | { kind: "instruction"; target: string; value: string; } | { attributes: Record<string, ... | ...> & { [qualifiedName: `${(...)}:${(...)}`]: ... | ...; }; content: (string | XmlComment | XmlInstruction | GenericElement)[]; name: string; namespaces?: Record<string, string>; namespaceURI: string; prefix?: string; })[]

name

string

namespaces?

Record<string, string>

namespaceURI

string

prefix?

string

Returns

partOf[]

descendants

descendants: (parent?: {
  attributes: Record<string, string | undefined> & {
   [qualifiedName: `${string}:${string}`]: string | undefined;
  };
  content: (
     | string
     | {
     kind: "comment";
     value: string;
   }
     | {
     kind: "instruction";
     target: string;
     value: string;
   }
     | {
     attributes: Record<string, ... | ...> & {
      [qualifiedName: `${(...)}:${(...)}`]: ... | ...;
     };
     content: (string | XmlComment | XmlInstruction | GenericElement)[];
     name: string;
     namespaces?: Record<string, string>;
     namespaceURI: string;
     prefix?: string;
  })[];
  name: string;
  namespaces?: Record<string, string>;
  namespaceURI: string;
  prefix?: string;
}) => partOf[];

Parameters

parent?
attributes

Record<string, string | undefined> & { [qualifiedName: `${string}:${string}`]: string | undefined; }

content

( | string | { kind: "comment"; value: string; } | { kind: "instruction"; target: string; value: string; } | { attributes: Record<string, ... | ...> & { [qualifiedName: `${(...)}:${(...)}`]: ... | ...; }; content: (string | XmlComment | XmlInstruction | GenericElement)[]; name: string; namespaces?: Record<string, string>; namespaceURI: string; prefix?: string; })[]

name

string

namespaces?

Record<string, string>

namespaceURI

string

prefix?

string

Returns

partOf[]

elementName

elementName: string = definition.name;

from

from: (parent?: {
  attributes: Record<string, string | undefined> & {
   [qualifiedName: `${string}:${string}`]: string | undefined;
  };
  content: (
     | string
     | {
     kind: "comment";
     value: string;
   }
     | {
     kind: "instruction";
     target: string;
     value: string;
   }
     | {
     attributes: Record<string, ... | ...> & {
      [qualifiedName: `${(...)}:${(...)}`]: ... | ...;
     };
     content: (string | XmlComment | XmlInstruction | GenericElement)[];
     name: string;
     namespaces?: Record<string, string>;
     namespaceURI: string;
     prefix?: string;
  })[];
  name: string;
  namespaces?: Record<string, string>;
  namespaceURI: string;
  prefix?: string;
}) => partOf | undefined;

Parameters

parent?
attributes

Record<string, string | undefined> & { [qualifiedName: `${string}:${string}`]: string | undefined; }

content

( | string | { kind: "comment"; value: string; } | { kind: "instruction"; target: string; value: string; } | { attributes: Record<string, ... | ...> & { [qualifiedName: `${(...)}:${(...)}`]: ... | ...; }; content: (string | XmlComment | XmlInstruction | GenericElement)[]; name: string; namespaces?: Record<string, string>; namespaceURI: string; prefix?: string; })[]

name

string

namespaces?

Record<string, string>

namespaceURI

string

prefix?

string

Returns

partOf | undefined

is

is: (element?: {
  attributes: Record<string, string | undefined> & {
   [qualifiedName: `${string}:${string}`]: string | undefined;
  };
  content: (
     | string
     | {
     kind: "comment";
     value: string;
   }
     | {
     kind: "instruction";
     target: string;
     value: string;
   }
     | {
     attributes: Record<string, ... | ...> & {
      [qualifiedName: `${(...)}:${(...)}`]: ... | ...;
     };
     content: (string | XmlComment | XmlInstruction | GenericElement)[];
     name: string;
     namespaces?: Record<string, string>;
     namespaceURI: string;
     prefix?: string;
  })[];
  name: string;
  namespaces?: Record<string, string>;
  namespaceURI: string;
  prefix?: string;
}) => element is partOf;

Parameters

element?
attributes

Record<string, string | undefined> & { [qualifiedName: `${string}:${string}`]: string | undefined; }

content

( | string | { kind: "comment"; value: string; } | { kind: "instruction"; target: string; value: string; } | { attributes: Record<string, ... | ...> & { [qualifiedName: `${(...)}:${(...)}`]: ... | ...; }; content: (string | XmlComment | XmlInstruction | GenericElement)[]; name: string; namespaces?: Record<string, string>; namespaceURI: string; prefix?: string; })[]

name

string

namespaces?

Record<string, string>

namespaceURI

string

prefix?

string

Returns

element is partOf

namespaceURI

namespaceURI: string = definition.namespaceURI;

defaults

defaults: Partial<{
  relation?: relations;
} & {
[qualifiedName: `${string}:${string}`]: string | undefined;
}>;

read()

read(element?: {
  attributes: Record<string, string | undefined> & {
   [qualifiedName: `${string}:${string}`]: string | undefined;
  };
  content: (
     | string
     | {
     kind: "comment";
     value: string;
   }
     | {
     kind: "instruction";
     target: string;
     value: string;
   }
     | {
     attributes: Record<string, string | undefined> & {
      [qualifiedName: `${string}:${string}`]: string | undefined;
     };
     content: (string | XmlComment | XmlInstruction | GenericElement)[];
     name: string;
     namespaces?: Record<string, string>;
     namespaceURI: string;
     prefix?: string;
  })[];
  name: string;
  namespaces?: Record<string, string>;
  namespaceURI: string;
  prefix?: string;
}): 
  | {
  attributes: {
     relation?: relations;
   } & {
   [qualifiedName: `${string}:${string}`]: string | undefined;
  };
  children: {
     entity: entity_2 | undefined;
  };
}
  | undefined;

Parameters

element?
attributes

Record<string, string | undefined> & { [qualifiedName: `${string}:${string}`]: string | undefined; }

content

( | string | { kind: "comment"; value: string; } | { kind: "instruction"; target: string; value: string; } | { attributes: Record<string, string | undefined> & { [qualifiedName: `${string}:${string}`]: string | undefined; }; content: (string | XmlComment | XmlInstruction | GenericElement)[]; name: string; namespaces?: Record<string, string>; namespaceURI: string; prefix?: string; })[]

name

string

namespaces?

Record<string, string>

namespaceURI

string

prefix?

string

Returns

| { attributes: { relation?: relations; } & { [qualifiedName: `${string}:${string}`]: string | undefined; }; children: { entity: entity_2 | undefined; }; } | undefined

update()

update(
   element: partOf, 
   attributes: Partial<E["attributes"]>, 
   changes: Partial<F>
): partOf;

Parameters

element

partOf

attributes

Partial<E["attributes"]>

changes

Partial<F>

Returns

partOf