Examples of JPackage


Examples of org.ontoware.rdfreactor.generator.java.JPackage

        + ".TransitiveProperty", OWL.TransitiveProperty));
    // XML Schema

    //////////////////// java.net
    // IDs
    jm.addMapping(XSD._anyURI, new JClass(new JPackage("java.net"),
        URI.class.getName() + "", XSD._anyURI));

    /////////////////// java.lang
    // primitive types
    jm.addMapping(XSD._byte, new JClass(JPackage.JAVA_LANG, Byte.class
View Full Code Here

Examples of org.ontoware.rdfreactor.generator.java.JPackage

public class TestJModel {
 
  @Test
  public void testMapping() {
   
    JPackage jp = new JPackage("Package");
    JClass root = new JClass(jp,"Rootclass", new URIImpl("urn:java:class.Rootclass"));
    JModel jm = new JModel(root);
   
    URI testURI = new URIImpl("urn:test:classX");
    JClass testClass = new JClass(jp,"Testclass", testURI);
View Full Code Here

Examples of org.ontoware.rdfreactor.generator.java.JPackage

  public static final String outdir = "./target/test-gen";

  @Test
  public void testWrite() throws Exception {
    JModel jm = new JModel(JClass.RDFS_CLASS);
    JPackage jp = new JPackage("test");
    jm.addPackage(jp);
    JClass jc1 = new JClass(jp, "Person", new URIImpl("urn:ex:Person"));
    jc1.setComment("All persons in the world");
    jc1.setJavaSuperclass(new JClass(new JPackage(""),"org.ontoware.rdfreactor.runtime.ReactorRuntimeEntity",new URIImpl("urn:ex:object")));
    jp.getClasses().add(jc1);

    // deprecated
    // JProperty jprop1 = new JProperty("age", new
    // JAttribute(Integer.class),
    // URIUtils.createURI("schema://age"), 1, 1);
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.