@constructor
@for kity.PathAnimator

@grammar new kity.Path.Animator(path)

@param  {String|PathSegment} path 目标形状的路径数据
432959
function(path) {
                this.callBase({
                    beginValue: function(target) {
                        this.beginPath = target.getPathData();
                        return 0;
                    },
                    finishValue: 1,
                    setter: function(target, value) {
                        target.setPathData(g.pathTween(this.beginPath, path, value));
                    }
                });
            }
656485
function parse(path) {
  const data = [];
  const p = String(path).trim();

  // A path data segment (if there is one) must begin with a "moveto" command
  if (p[0] !== 'M' && p[0] !== 'm') {
    return data;
  }

  p.replace(SEGMENT_PATTERN, (_, command, args) => {
    let type = command.toLowerCase();
    let theArgs = parseValues(args);
    let theCommand = command;
    // overloaded moveTo
    if (type === 'm' && theArgs.length > 2) {
      data.push([theCommand].concat(theArgs.splice(0, 2)));
      type = 'l';
      theCommand = theCommand === 'm' ? 'l' : 'L';
    }

    // Ignore invalid commands
    if (theArgs.length < ARG_LENGTH[type]) {
      return '';
    }

    data.push([theCommand].concat(theArgs.splice(0, ARG_LENGTH[type])));

    // The command letter can be eliminated on subsequent commands if the
    // same command is used multiple times in a row (e.g., you can drop the
    // second "L" in "M 100 200 L 200 100 L -100 -200" and use
    // "M 100 200 L 200 100 -100 -200" instead).
    while (theArgs.length >= ARG_LENGTH[type] && theArgs.length && ARG_LENGTH[type]) {
      data.push([theCommand].concat(theArgs.splice(0, ARG_LENGTH[type])));
    }

    return '';
  });
  return data;
}
1165933
public BaseNode<V> transition(char path)
    {
        BaseNode<V> cur = this;
        cur = cur.getChild(path);
        if (cur == null || cur.status == Status.UNDEFINED_0) return null;
        return cur;
    }
604419
function transform(path) {
    if (shouldProcess(path)) {
        const renderer = Renderer.forPath(path);
        transformer(path.node, renderer, buildErrorHandler(path));
        // replace the render call if present, else replace the JSX
        if (Renderer.isParent(path)) {
            path.parentPath.replaceWith(renderer.toFunctionCall());
        } else {
            path.replaceWith(renderer.toFunctionCall());
        }
    }
}
115283
private void doFilledPath(SvgElement obj, Path path)
   {
      // First check for pattern fill. It requires special handling.
      if (state.style.fill instanceof SVG.PaintReference)
      {
         SVG.SvgObject  ref = document.resolveIRI(((SVG.PaintReference) state.style.fill).href);
         if (ref instanceof SVG.Pattern) {
            SVG.Pattern  pattern = (SVG.Pattern)ref;
            fillWithPattern(obj, path, pattern);
            return;
         }
      }

      // Otherwise do a normal fill
      canvas.drawPath(path, state.fillPaint);
   }
1330261
function (segment) {

            var segmentPath = Series.prototype.getSegmentPath.call(this, segment), // call base method
              areaSegmentPath = [].concat(segmentPath), // work on a copy for the area path
              i,
              options = this.options,
              segLength = segmentPath.length,
              translatedThreshold = this.yAxis.getThreshold(options.threshold), // #2181
              yBottom;

            if (segLength === 3) { // for animation from 1 to two points
                areaSegmentPath.push(L, segmentPath[1], segmentPath[2]);
            }
            if (options.stacking && !this.closedStacks) {

                // Follow stack back. Todo: implement areaspline. A general solution could be to
                // reverse the entire graphPath of the previous series, though may be hard with
                // splines and with series with different extremes
                for (i = segment.length - 1; i >= 0; i--) {

                    yBottom = pick(segment[i].yBottom, translatedThreshold);

                    // step line?
                    if (i < segment.length - 1 && options.step) {
                        areaSegmentPath.push(segment[i + 1].plotX, yBottom);
                    }

                    areaSegmentPath.push(segment[i].plotX, yBottom);
                }

            } else { // follow zero line back
                this.closeSegment(areaSegmentPath, segment, translatedThreshold);
            }
            this.areaPath = this.areaPath.concat(areaSegmentPath);
            return segmentPath;
        }
419036
public void applyToPath(Matrix transform, Path path) {
        for (int i = 0, size = operations.size(); i < size; i++) {
            PathOperation operation = operations.get(i);
            operation.applyToPath(transform, path);
        }
    }
787246
public void setPath(List<? extends S> path, Direction1D direction) {
		this.path = path == null || path.isEmpty() ? null : new ArrayList<>(path);
		this.firstSegmentDirection = detectFirstSegmentDirection(direction);
	}
93502
public void addPath(String path) {
        if (path == null) {
            return;
        }
        String[] pathComponents = path.split("/");
        TrieNode parent = rootNode;
        String part = null;
        if (pathComponents.length <= 1) {
            throw new IllegalArgumentException("Invalid path " + path);
        }
        for (int i=1; i<pathComponents.length; i++) {
            part = pathComponents[i];
            if (parent.getChild(part) == null) {
                parent.addChild(part, new TrieNode(parent));
            }
            parent = parent.getChild(part);
        }
        parent.setProperty(true);
    }
1102589
function buildPath(lines, jumpSize, jumpType) {

        var path = new g.Path();
        var segment;

        // first move to the start of a first line
        segment = g.Path.createSegment('M', lines[0].start);
        path.appendSegment(segment);

        // make a paths from lines
        joint.util.toArray(lines).forEach(function(line, index) {

            if (line.isJump) {
                var angle, diff;

                var control1, control2;

                if (jumpType === 'arc') { // approximates semicircle with 2 curves
                    angle = -90;
                    // determine rotation of arc based on difference between points
                    diff = line.start.difference(line.end);
                    // make sure the arc always points up (or right)
                    var xAxisRotate = Number((diff.x < 0) || (diff.x === 0 && diff.y < 0));
                    if (xAxisRotate) angle += 180;

                    var midpoint = line.midpoint();
                    var centerLine = new g.Line(midpoint, line.end).rotate(midpoint, angle);

                    var halfLine;

                    // first half
                    halfLine = new g.Line(line.start, midpoint);

                    control1 = halfLine.pointAt(2 / 3).rotate(line.start, angle);
                    control2 = centerLine.pointAt(1 / 3).rotate(centerLine.end, -angle);

                    segment = g.Path.createSegment('C', control1, control2, centerLine.end);
                    path.appendSegment(segment);

                    // second half
                    halfLine = new g.Line(midpoint, line.end);

                    control1 = centerLine.pointAt(1 / 3).rotate(centerLine.end, angle);
                    control2 = halfLine.pointAt(1 / 3).rotate(line.end, -angle);

                    segment = g.Path.createSegment('C', control1, control2, line.end);
                    path.appendSegment(segment);

                } else if (jumpType === 'gap') {
                    segment = g.Path.createSegment('M', line.end);
                    path.appendSegment(segment);

                } else if (jumpType === 'cubic') { // approximates semicircle with 1 curve
                    angle = line.start.theta(line.end);

                    var xOffset = jumpSize * 0.6;
                    var yOffset = jumpSize * 1.35;

                    // determine rotation of arc based on difference between points
                    diff = line.start.difference(line.end);
                    // make sure the arc always points up (or right)
                    xAxisRotate = Number((diff.x < 0) || (diff.x === 0 && diff.y < 0));
                    if (xAxisRotate) yOffset *= -1;

                    control1 = g.Point(line.start.x + xOffset, line.start.y + yOffset).rotate(line.start, angle);
                    control2 = g.Point(line.end.x - xOffset, line.end.y + yOffset).rotate(line.end, angle);

                    segment = g.Path.createSegment('C', control1, control2, line.end);
                    path.appendSegment(segment);
                }

            } else {
                segment = g.Path.createSegment('L', line.end);
                path.appendSegment(segment);
            }
        });

        return path;
    }
640239
function (path, next) {
      var t$ = this

      var files = typeof path === 'string' ? [path] : path

      for (var i = 0; i < files.length; i++) {
        var name = files[i].replace(/^\s|\s$/g, '')
        var att = name.split('.')
        var ext = att[att.length - 1].toLowerCase()
        var isCSS = ext === 'css'
        var tag = isCSS ? 'link' : 'script'
        var attr = isCSS ? ' type=\'text/css\' rel=\'stylesheet\' ' : ' language=\'javascript\' type=\'text/javascript\' '
        var link = (isCSS ? 'href' : 'src') + '=\'' + t$.includePath + name + '\''
        if ($(tag + '[' + link + ']').length === 0) {
          if ($.inArray(path, t$.cache) === -1) {
            t$.cache.push(path)
            var content = '<' + tag + attr + link + '></' + tag + '>'
            isCSS ? $('head').append(content) : $('head').append(content)
          }
        }
      }
      next && next()
    }
1140403
function(path, handler) {
    var node = trie.define(path)[0];

    if (typeof handler !== 'function') {
      throw new Error('invalid handler');
    }

    node.handler = handler;
  }
900766
function(path) {
    var state = window.history.state,
        initialURL = get(this, '_initialURL');

    path = this.formatPath(path);

    if ((initialURL !== path && !state) || (state && state.path !== path)) {
      window.history.pushState({ path: path }, null, path);
    }
  }
575586
function createRule(path, handler) {
  if ('*' !== path && 0 != path.indexOf(watch.__base)) {
    path = watch.__base + (path == '/' ? '' : path)
  }
  let rule = pathToRegExp(path)
  if (handler instanceof String) {
    let target = handler
    handler = function() {
      watch({
        url: target
      })
    }
  }
  rule.handler = handler

  return rule
}
634804
public void changePathInURL(String path, boolean changeHistory) {
        jcrURL.setPath(path);
        if (changeHistory) {
            htmlHistory.newItem(jcrURL.toString(), false);
        }
    }
124577
private void registerDirectoryTree(Path path) {
        try {
            Files.walkFileTree(path, new SimpleFileVisitor<Path>() {
                @Override
                public FileVisitResult preVisitDirectory(Path dir, BasicFileAttributes attrs)
                        throws IOException {
                    registerDirectory(dir);
                    return FileVisitResult.CONTINUE;
                }
            });
        } catch (IOException ex) {
            LOGGER.error("监控目录失败：" + path.toAbsolutePath(), ex);
        }
    }
533094
function(path) {
            if (!path.inList) {
              return;
            }

            const { node } = path;
            if (node.kind !== "var") {
              return;
            }

            const next = path.getSibling(path.key + 1);
            if (!next.isForStatement()) {
              return;
            }

            const init = next.get("init");
            if (!init.isVariableDeclaration({ kind: node.kind })) {
              return;
            }

            const declarations = node.declarations.concat(
              init.node.declarations
            );

            // temporary workaround to forces babel recalculate scope,
            // references and binding until babel/babel#4818 resolved
            path.remove();
            init.replaceWith(t.variableDeclaration("var", declarations));
          }