Examples of Doc


Examples of com.joshondesign.xml.Doc

        }
        return null;
    }

    public static List<SNode> loadShapes(File file, ZipFile zipFile) throws Exception {
        Doc doc = XMLParser.parse(new FileInputStream(file));
        doc.setBaseURI(file.toURI());
        List<SNode> shapes = new ArrayList<SNode>();
        for(Elem e : doc.xpath("/sketchy/*")) {
            shapes.add(loadAnyShape(e,zipFile));
        }
        return shapes;
    }
View Full Code Here

Examples of com.joshondesign.xml.Doc

    private static SketchDocument importSVG(InputStream stream) throws Exception {
        SketchDocument sdoc = new SketchDocument();
        sdoc.removePage(sdoc.getCurrentPage());
        SketchDocument.SketchPage page = sdoc.addPage();
        u.p("parsing");
        Doc doc = XMLParser.parse(stream);
        u.p("parsed");
        Elem svg = doc.xpathElement("/svg");
        for(Elem n : svg.xpath("./*")) {
            u.p("node = " + n + " " + n.name());
            SNode node = loadNode(n);
            if(node != null) page.add(node);
        }
View Full Code Here

Examples of com.joshondesign.xml.Doc

                return devices;
            }
            for(File xml : new File(basedir,"hardware/boards/").listFiles()) {
                Util.p("parsing: " + xml.getCanonicalPath());
                try {
                    Doc doc = XMLParser.parse(xml);
                    Elem e = doc.xpathElement("/board");
                    Device d = new Device();
                    d.name = e.attr("name");
                    d.protocol = e.attr("protocol");
                    d.maximum_size = Integer.parseInt(e.attr("maximum-size"));
                    d.upload_speed = Integer.parseInt(e.attr("upload-speed"));
View Full Code Here

Examples of com.joshondesign.xml.Doc

        }
    }

    private Example parseExample(File file) {
        try {
            Doc doc = XMLParser.parse(file);
            Elem e = doc.xpathElement("/example");
            Example ex = new Example();
            ex.name = e.attr("name");
            for(Elem k : e.xpath("keyword")) {
                ex.keywords.add(k.text().toLowerCase());
                //Util.p("added keyword: " + k.text().toLowerCase());
View Full Code Here

Examples of com.m11n.android.model.Doc

    {
      item = new Sample();
    }
    else if(Doc.ELEMENT_NAME.equals(parent.getNodeName()))
    {
      item = new Doc();
    }
    else if(Tool.ELEMENT_NAME.equals(parent.getNodeName()))
    {
      item = new Tool();
    }
View Full Code Here

Examples of com.pogofish.jadt.ast.Doc

    public void testMinimal() {
        final Parser parser = new StandardParser(PARSER_IMPL_FACTORY);
        final ParseResult result = parser.parse(new StringSource("ParserTest",
                "Foo = Foo"));

        assertEquals(new ParseResult(new Doc("ParserTest", EMPTY_PKG, NO_IMPORTS, list(_DataType(NO_COMMENTS, NO_ANNOTATIONS, "Foo", NO_FORMAL_TYPE_ARGUMENTS, NO_EXTENDS, NO_IMPLEMENTS,
                list(_Constructor(NO_COMMENTS, "Foo", Util.<Arg> list()))))), Util.<SyntaxError>list()), result);
    }
View Full Code Here

Examples of com.stuffwithstuff.magpie.Doc

        instance = new MethodWrapper((Method) instance);
      }
     
      // Look for documentation.
      String doc = "";
      Doc docAnnotation = (Doc) innerClass.getAnnotation(Doc.class);
      if (docAnnotation != null) {
        doc = docAnnotation.value();
      }
     
      Callable callable = new IntrinsicCallable(pattern, doc, (Intrinsic) instance, scope);
     
      // Register it.
View Full Code Here

Examples of com.sun.javadoc.Doc

    text(jreLink);
    endln();
  }

  private void emitLocation(Doc doc) {
    Doc parent = getParentDoc(doc);
    if (parent != null) {
      beginln("location");
      emitLocationLink(parent);
      endln();
    }
View Full Code Here

Examples of com.sun.javadoc.Doc

    } else {
      throw new IllegalStateException(
          "Expected only a member, type, or package");
    }

    Doc parent = getParentDoc(doc);
    if (parent != null) {
      emitLocationLink(parent);
    }

    beginln("link", "ref", myId);
View Full Code Here

Examples of com.sun.javadoc.Doc

    if (doc instanceof MemberDoc) {
      MemberDoc memberDoc = (MemberDoc) doc;
      return memberDoc.containingClass();
    } else if (doc instanceof ClassDoc) {
      ClassDoc classDoc = (ClassDoc) doc;
      Doc enclosingClass = classDoc.containingClass();
      if (enclosingClass != null) {
        return enclosingClass;
      } else {
        return classDoc.containingPackage();
      }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.