Package xtc.tree

Examples of xtc.tree.Comment


   * @param m The module.
   */
  protected void printDocumentation(Module m) {
    if ((! verbose) || (null == m.documentation)) return;

    Comment c    = m.documentation;
    int     size = c.text.size();

    if (0 == size) {
      // Nothing to print.

View Full Code Here


  }

  /** Copy the specified comment. */
  public Comment visit(Comment c) {
    Node    node  = (Node)dispatch(c.getNode());
    Comment copy  = new Comment(c.kind, new ArrayList<String>(c.text), node);
    copy.setLocation(c);

    return copy;
  }
View Full Code Here

   * @return The commented node.
   */
  public static Node comment(Node node, String... text) {
    final List<String> l = new ArrayList<String>(text.length);
    for (String s : text) l.add(s);
    return new Comment(Comment.Kind.DOCUMENTATION, l, node);
  }
View Full Code Here

    File file = new File(runtime.getOutputDirectory(), name);
    printer   = new Printer(new PrintWriter(runtime.getWriter(file)));
  }

  protected void printDocumentation(Module m) {
    Comment c = m.documentation;

    // Make sure we have something to print.
    if (! verbose || null == c || c.text.isEmpty()) {
      return;
    }
View Full Code Here

TOP

Related Classes of xtc.tree.Comment

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.