Class DockerAbstractNodeAbstract

Hierarchy (view full)

Constructors

Properties

annotations: string[] = []
children: AllDockerNodes[] = []

The children nodes

isChanged: boolean = false
parent: AllDockerNodes = null

The parent node

type: "DOCKER-ADD" | "DOCKER-ADD-SOURCE" | "DOCKER-ADD-TARGET" | "DOCKER-ARG" | "DOCKER-CMD" | "DOCKER-KEYWORD" | "DOCKER-CMD-ARG" | "DOCKER-COPY" | "DOCKER-COPY-SOURCE" | "DOCKER-COPY-TARGET" | "DOCKER-ENTRYPOINT" | "DOCKER-ENTRYPOINT-ARG" | "DOCKER-ENTRYPOINT-EXECUTABLE" | "DOCKER-ENV" | "DOCKER-EXPOSE" | "DOCKER-FILE" | "DOCKER-LABEL" | "DOCKER-MAINTAINER" | "DOCKER-FROM" | "DOCKER-IMAGE-DIGEST" | "DOCKER-IMAGE-ALIAS" | "DOCKER-IMAGE-NAME" | "DOCKER-IMAGE-REPO" | "DOCKER-IMAGE-TAG" | "DOCKER-LITERAL" | "DOCKER-NAME" | "DOCKER-PATH" | "DOCKER-PORT" | "DOCKER-JSON-INSTRUCTION" | "DOCKER-RUN" | "DOCKER-SHELL" | "DOCKER-SHELL-ARG" | "DOCKER-SHELL-EXECUTABLE" | "DOCKER-USER" | "DOCKER-VOLUME" | "DOCKER-WORKDIR" | "DOCKER-COMMENT" | "DOCKER-ONBUILD" | "DOCKER-STOPSIGNAL" | "DOCKER-HEALTHCHECK" | "DOCKER-FLAG"

Accessors

Methods

  • Get the first node of the given type

    Type Parameters

    Parameters

    • nodeType: (new (t) => C)

      the type of the node to find

        • new (t): C
        • Parameters

          • t: any

          Returns C

    Returns C

    the node of the given type or null if not found

  • Iterate over the children nodes (non recursive)

    Parameters

    • callback: ((node, index) => void)

      callback function to call for each node

        • (node, index): void
        • Parameters

          Returns void

    • Optional filter: ((node) => boolean)

    Returns void

  • Returns {
        children?: {
            children?: { type: string; position: { lineStart: number; columnStart: number; lineEnd: number; columnEnd: number; }; children?: ...[]; value?: string; }[];
            position: {
                columnEnd: number;
                columnStart: number;
                lineEnd: number;
                lineStart: number;
            };
            type: string;
            value?: string;
        }[];
        position: {
            columnEnd: number;
            columnStart: number;
            lineEnd: number;
            lineStart: number;
        };
        type: string;
        value?: string;
    }

    • Optional children?: {
          children?: { type: string; position: { lineStart: number; columnStart: number; lineEnd: number; columnEnd: number; }; children?: ...[]; value?: string; }[];
          position: {
              columnEnd: number;
              columnStart: number;
              lineEnd: number;
              lineStart: number;
          };
          type: string;
          value?: string;
      }[]
    • position: {
          columnEnd: number;
          columnStart: number;
          lineEnd: number;
          lineStart: number;
      }
      • columnEnd: number
      • columnStart: number
      • lineEnd: number
      • lineStart: number
    • type: string
    • Optional value?: string
  • Return a string representation of this node

    Parameters

    • asPrettyPrint: boolean = true

      true if the output should be pretty printed

    Returns string

    a string representation of this node

  • traverse all children recursively

    Parameters

    • callback: ((node) => boolean | void)

      returns false to stop the traverse

        • (node): boolean | void
        • Parameters

          Returns boolean | void

    • __namedParameters: {
          includeSelf: boolean;
      } = ...
      • includeSelf: boolean

    Returns boolean

    false if not everything has been traversed

Generated using TypeDoc