xml-disassembler 1.7.0 → 1.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,2 @@
1
+ import { XmlElement } from "@src/types/types";
2
+ export declare function buildGroupedNestedFile(tag: string, elements: XmlElement[], disassembledPath: string, rootElementName: string, rootElementHeader: string, xmlDeclarationStr: string, indent: string, format: string): Promise<void>;
@@ -3,6 +3,7 @@ export declare class DisassembleXMLFileHandler {
3
3
  disassemble(xmlAttributes: {
4
4
  filePath: string;
5
5
  uniqueIdElements?: string;
6
+ strategy?: string;
6
7
  prePurge?: boolean;
7
8
  postPurge?: boolean;
8
9
  ignorePath?: string;
@@ -10,6 +11,7 @@ export declare class DisassembleXMLFileHandler {
10
11
  }): Promise<void>;
11
12
  processFile(xmlAttributes: {
12
13
  dirPath: string;
14
+ strategy: string;
13
15
  filePath: string;
14
16
  uniqueIdElements?: string;
15
17
  prePurge: boolean;
@@ -3,5 +3,6 @@ export { DisassembleXMLFileHandler } from "./handlers/disassembleXMLFileHandler"
3
3
  export { parseXML } from "./parsers/parseXML";
4
4
  export { buildXMLString } from "./builders/buildXMLString";
5
5
  export { XmlElement } from "./types/types";
6
+ export { transformToYaml, transformToIni, transformToJson, transformToJson5, transformToToml, } from "./transformers/transformers";
6
7
  export declare function setLogLevel(level: string): void;
7
8
  export declare const logger: import("log4js").Logger;
@@ -0,0 +1,7 @@
1
+ import { XmlElementParams, XmlElement } from "@src/types/types";
2
+ export declare function parseElement(params: XmlElementParams): Promise<{
3
+ leafContent: string;
4
+ leafCount: number;
5
+ hasNestedElements: boolean;
6
+ nestedGroups: Record<string, XmlElement[]>;
7
+ }>;
@@ -4,7 +4,7 @@ export type XmlElement = {
4
4
  export type XmlElementParams = {
5
5
  element: XmlElement;
6
6
  disassembledPath: string;
7
- uniqueIdElements: string | undefined;
7
+ uniqueIdElements?: string;
8
8
  rootElementName: string;
9
9
  rootElementHeader: string;
10
10
  key: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "xml-disassembler",
3
- "version": "1.7.0",
3
+ "version": "1.9.0",
4
4
  "description": "Disassemble XML files into smaller, more manageable files and reassemble the XML when needed.",
5
5
  "author": "Matt Carvin",
6
6
  "license": "ISC",