Java API - Editor class for an XML schema

Hi,
i am very interesting in Java API. I would like to make an editor class for an XML schema. (I will create XML files in the current project based on this XML schema.) What step's are require for this editor class?
Regards
Gabor

DavidThi808 wrote:
jtahlborn wrote:
you can provide a schema when parsing an xml document in order to check for schema conformance, but that isn't going to affect your XPath queries at all. DOM content is never anything but strings.In the case of both dom4j/jaxen and the .NET runtime the values returned from XPath queries when a schema is provided are typed. So you get back numbers, dates, and booleans as well as strings. And for numbers you get correct comparisons so 20 > 1.i guess it's possible. i use schemas when parsing xml, and i've used xpath (infrequently), but i'm not sure that i've ever used them together in a way that i would see functionality like that.
FYI, you use http://docs.oracle.com/javase/6/docs/api/javax/xml/parsers/DocumentBuilderFactory.html#setSchema%28javax.xml.validation.Schema%29 to specify a schema while parsing with a DocumentBuilder.

Similar Messages

  • Maximum length for an XML schema

    Hi everybody,
    Is there a limit on the maximum length for an XML schema? I am trying to register an XML schema using dbms_xmlschema.registerSchema(). The schema registration process seems to go fine when the length of the schema is short. But the registration process always hangs when I increase the XML schema with additional types/elements. Is there a limit on the maximum length of the XML schema with regards to registering it to Oracle?
    Thanks!
    IK

    Hi Erhan,
    Let's say I have a really big XML schema in file "schemaA.xsd", like so:
    <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:sampleA="http://abc.com/schemaA" targetNamespace="http://abc.com/schemaA">
    <xsd:element name="Employee">
    <xsd:sequence>
    <xsd:element name="Address" type="sampleA:AddressType"/>
    <xsd:element name="Contact" type="sampleA:ContactInfoType"/>
    </xsd:element>
    <xsd:complexType name="AddressType">......</xsd:complexType>
    <xsd:complexType name="ContactInfoType">....</xsd:complexType>
    </xsd:schema>
    I can separate this schema into multiple smaller schemas (<32KB) by using the proper imports:
    In file "sampleA.xsd":
    <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:sampleB="http://abc.com/schemaB"
    xmlns:sampleA="http://abc.com/schemaA" targetNamespace="http://abc.com/schemaA">
    <xsd:import namespace="http://abc.com/schemaB" schemaLocation="schemaB.xsd"/>
    <xsd:element name="Employee">
    <xsd:sequence>
    <xsd:element name="Address" type="sampleB:AddressType"/>
    <xsd:element name="Contact" type="sampleB:ContactInfoType"/>
    </xsd:element>
    </xsd:schema>
    And in file "sampleB.xsd", I might have something like this:
    <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:sampleB="http://abc.com/schemaB" targetNamespace="http://abc.com/schemaB">
    <xsd:complexType name="AddressType">......</xsd:complexType>
    <xsd:complexType name="ContactInfoType">....</xsd:complexType>
    </xsd:schema>
    So, you see how I have separated that one really big XML schema in file "schemaA.xsd" into two XML schema files: "schemaA.xsd" and "schemaB.xsd". Also, I have added <import> tags in schemaA.xsd to refer to elements, complext types, etc. defined in schemaB.xsd. So long as these schema files are < 32KB, I can register them (using dbms_xmlschema.registerSchema()) without any problems into Oracle.
    Let me know if what I said above is not too clear. Hope you find your solution soon!
    Thanks!
    Irene

  • MDM JAVA API SCA file for MDM 7.1 SP04

    I need to download MDM JAVA API SCA file for MDM 7.1 SP04. When I added to the download basket through service marketplace it is looking for the approval process, just for the API file. I was able to get the other files though like webdynpro framework, change tracker. We haven't setup the Solution Manager yet. It might take a while. Meanwhile is there any other way to get the SCA file.
    Thanks

    Opened message with SAP and they have approved the download basket. Now able to download the sca file.

  • Java API - PublicReportServiceClient.class

    I have a BI Publisher API, publicreportserviceclient.class, that was created by a contractor in 2007 that needs to be reengineered. Code anomolies appear when opening the class in Oracle JDeveloper 11g Release 2. The code follows. What is the purpose of the _mthclass$(String s) methode.  There are many occurances of $, why?  How can I remove these unnecessary $ characters in the code without destroying the code?  Kinda lost, please help! Thanks.
    package oracle.apps.xdo.webservice;
    import java.io.FileOutputStream;
    import java.util.Properties;
    import javax.xml.namespace.QName;
    import javax.xml.rpc.ParameterMode;
    import org.apache.axis.client.Call;
    import org.apache.axis.client.Service;
    import org.apache.axis.encoding.XMLType;
    // Referenced classes of package oracle.apps.xdo.webservice:
    //      ParamNameValue, ReportRequest, ReportResponse
    public class PublicReportServiceClient
    Couldn't fully decompile method _mthclass$
    Couldn't resolve all exception handlers in method _mthclass$
      private static Service service = null;
      private static Call call = null;
      private static Class class$oracle$apps$xdo$webservice$ReportRequest; /* synthetic field */
      private static Class class$org$apache$axis$encoding$ser$BeanSerializerFactory; /* synthetic field */
      private static Class class$org$apache$axis$encoding$ser$BeanDeserializerFactory; /* synthetic field */
      private static Class class$oracle$apps$xdo$webservice$ParamNameValue; /* synthetic field */
      private static Class class$oracle$apps$xdo$webservice$ReportResponse; /* synthetic field */
      public static void main(String args[])
        throws Exception
        callRunReport("Report", "pdf", "11-NOV-2009", "19-NOV-2009", "4", "13", "13-NOV-2009");
      public static void callRunReport(String reportName, String reportType, String a_DATE, String b_DATE, String c_NUMBER, String d_NUMBER, String e_DATE)
        throws Exception
        Properties props = new Properties();
        ClassLoader loader = Thread.currentThread().getContextClassLoader();
        java.io.InputStream in = loader.getResourceAsStream("connInfoCHANGEME.properties");
        props.load(in);
        String url = props.getProperty("BIPubWebServiceURL");
        service = new Service();
        call = (Call)service.createCall();
        call.setTargetEndpointAddress(url);
        call.setTimeout(new Integer(0x36ee80));
        QName reportReq = new QName("http://xmlns.oracle.com/oxp/service/PublicReportService", "ReportRequest");
        Class cls = class$oracle$apps$xdo$webservice$ReportRequest == null && (class$oracle$apps$xdo$webservice$ReportRequest = _mthclass$("oracle.apps.xdo.webservice.ReportRequest")) == null ? class$oracle$apps$xdo$webservice$ReportRequest : class$oracle$apps$xdo$webservice$ReportRequest;
        call.registerTypeMapping(cls, reportReq, class$org$apache$axis$encoding$ser$BeanSerializerFactory == null && (class$org$apache$axis$encoding$ser$BeanSerializerFactory = _mthclass$("org.apache.axis.encoding.ser.BeanSerializerFactory")) == null ? class$org$apache$axis$encoding$ser$BeanSerializerFactory : class$org$apache$axis$encoding$ser$BeanSerializerFactory, class$org$apache$axis$encoding$ser$BeanDeserializerFactory == null && (class$org$apache$axis$encoding$ser$BeanDeserializerFactory = _mthclass$("org.apache.axis.encoding.ser.BeanDeserializerFactory")) == null ? class$org$apache$axis$encoding$ser$BeanDeserializerFactory : class$org$apache$axis$encoding$ser$BeanDeserializerFactory);
        QName nmvals = new QName("http://xmlns.oracle.com/oxp/service/PublicReportService", "ParamNameValue");
        cls = class$oracle$apps$xdo$webservice$ParamNameValue == null && (class$oracle$apps$xdo$webservice$ParamNameValue = _mthclass$("oracle.apps.xdo.webservice.ParamNameValue")) == null ? class$oracle$apps$xdo$webservice$ParamNameValue : class$oracle$apps$xdo$webservice$ParamNameValue;
        call.registerTypeMapping(cls, nmvals, class$org$apache$axis$encoding$ser$BeanSerializerFactory == null && (class$org$apache$axis$encoding$ser$BeanSerializerFactory = _mthclass$("org.apache.axis.encoding.ser.BeanSerializerFactory")) == null ? class$org$apache$axis$encoding$ser$BeanSerializerFactory : class$org$apache$axis$encoding$ser$BeanSerializerFactory, class$org$apache$axis$encoding$ser$BeanDeserializerFactory == null && (class$org$apache$axis$encoding$ser$BeanDeserializerFactory = _mthclass$("org.apache.axis.encoding.ser.BeanDeserializerFactory")) == null ? class$org$apache$axis$encoding$ser$BeanDeserializerFactory : class$org$apache$axis$encoding$ser$BeanDeserializerFactory);
        QName reportRespqn = new QName("http://xmlns.oracle.com/oxp/service/PublicReportService", "ReportResponse");
        cls = class$oracle$apps$xdo$webservice$ReportResponse == null && (class$oracle$apps$xdo$webservice$ReportResponse = _mthclass$("oracle.apps.xdo.webservice.ReportResponse")) == null ? class$oracle$apps$xdo$webservice$ReportResponse : class$oracle$apps$xdo$webservice$ReportResponse;
        call.registerTypeMapping(cls, reportRespqn, class$org$apache$axis$encoding$ser$BeanSerializerFactory == null && (class$org$apache$axis$encoding$ser$BeanSerializerFactory = _mthclass$("org.apache.axis.encoding.ser.BeanSerializerFactory")) == null ? class$org$apache$axis$encoding$ser$BeanSerializerFactory : class$org$apache$axis$encoding$ser$BeanSerializerFactory, class$org$apache$axis$encoding$ser$BeanDeserializerFactory == null && (class$org$apache$axis$encoding$ser$BeanDeserializerFactory = _mthclass$("org.apache.axis.encoding.ser.BeanDeserializerFactory")) == null ? class$org$apache$axis$encoding$ser$BeanDeserializerFactory : class$org$apache$axis$encoding$ser$BeanDeserializerFactory);
        call.setOperationName(new QName("http://xmlns.oracle.com/oxp/service/PublicReportService", "runReport"));
        call.addParameter("ReportRequest", reportReq, ParameterMode.IN);
        call.addParameter("userID", XMLType.XSD_STRING, ParameterMode.IN);
        call.addParameter("password", XMLType.XSD_STRING, ParameterMode.IN);
        call.setReturnClass(class$oracle$apps$xdo$webservice$ReportResponse == null && (class$oracle$apps$xdo$webservice$ReportResponse = _mthclass$("oracle.apps.xdo.webservice.ReportResponse")) == null ? class$oracle$apps$xdo$webservice$ReportResponse : class$oracle$apps$xdo$webservice$ReportResponse);
        ParamNameValue paramNmVals[] = new ParamNameValue[5];
        paramNmVals[0] = new ParamNameValue("a_date", new String[] {
          a_START_DATE
        paramNmVals[1] = new ParamNameValue("b_date", new String[] {
          b_END_DATE
        paramNmVals[2] = new ParamNameValue("c_volume", new String[] {
          c_NUMBER
        paramNmVals[3] = new ParamNameValue("d_number", new String[] {
          d_NUMBER
        paramNmVals[4] = new ParamNameValue("e_date", new String[] {
          e_DATE
        String reportPath = props.getProperty("BIPubReportsFolder");
        reportPath = reportPath + "/" + reportName + "/" + reportName + ".xdo";
        ReportRequest req = new ReportRequest(reportPath, paramNmVals, reportType, null, null);
        String bi_username = props.getProperty("BIPubUser");
        String bi_pass = props.getProperty("BIPubPass");
        ReportResponse reportResp = (ReportResponse)call.invoke(new Object[] {
          req, bi_username, bi_pass
        String bip_location = props.getProperty("BIPLOCATION");
        byte baReport[] = reportResp.getReportBytes();
        FileOutputStream fio = new FileOutputStream(bip_location);
        fio.write(baReport);
        fio.close();
      public PublicReportServiceClient()
      static Class _mthclass$(String s)
        s;
        Class.forName();
        return;
        JVM INSTR new #8   <Class NoClassDefFoundError>;
        JVM INSTR dup_x1 ;
        JVM INSTR swap ;
        getMessage();
        NoClassDefFoundError();
        throw ;
    }

    To get this to work, I added every file defined in OWB_HOME\owb\bin\admin\owb.classpath to my classpath. So far it is working.
    You could also look at OWB_HOME\owb\bin\win32\setowbenv.bat to see how all the environment variables are set before starting OWB.

  • Where are classes for oracle.xml.parser.v2?

    I have downloaded both V1 and V2 of the XML parser. I have managed to download the java classes under org.w3c.dom from www.w3.org but I can't find the classes under oracle.xml.parser.v2 (or without v2) anyway on technet. Both are required for import.
    I would have expected them to be in the ZIP files xmlparser_v1_0_2_0.zip and xmlparser_v2_0_2_7.zip but they don't seem to be. These contain the equivalent HTML files but not the class files themselves, so compiling the samples is not possible.
    Any help would be appreciated as this is becoming very frustrating.
    Thanks in advance
    Gary

    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by Steve Muench ([email protected]):
    The xmlparserv2.jar in the 2.0.2.7 download contains everything you need from DOM and SAX interfaces in the jar.<HR></BLOCKQUOTE>
    Many thanks Steve - yes unzipping the jar file corrects problem.

  • Can i generate java API from class files

    I have only class files. Is it possible to generate the java API using the javadoc.If yes, pls tell me how can i do??

    Also, Javadoc 1.4.2 will contain an unsupported option -Xclasses
    that should allow you to do this. You must pass in class names
    and use -classpath to find them. For com.package.MyClass
    at /home/classes/com/package/MyClass.class,
    you would run:
    javadoc -Xclasses -classpath /home/classes com.package.MyClass
    For mroe info, see:
    http://developer.java.sun.com/developer/bugParade/bugs/4720100.html-
    Doug Kramer
    Javadoc team

  • Writing own getLineNumber for parsing XML Schema

    I'm creating a XML Schema tool that checks that the user is creating valid Schema text.
    What I want to do is if the user has nested an element within a parent that it's not meant to. for example:
    <element name = "1">
            <element name = "2"/>
    </element>I want to return to the user the line number that the problem has occured.
    Because as far as the SAXParser is concerned this is valid XML I can't catch a SAXParseException.
    I'm using DOM to store the XML structure.
    Is there another way I can parse the document so that I can store the line number it orginially came from?
    Many thanks
    Alex

    Thats great, thanks.
    My problem now is how can I access the parent node using SAX().
    I have an arraylist for the parent of valid children, I need to check that the child node is infact one of these nodes.
    The problem being using SAX() I can access the previous node but if their are sibling nodes this will not identify the parent.
    This is the code I have so far:
    public class TestHandler extends DefaultHandler
         int lineNo = 1;
         public void startElement(String namespaceURI, String localname, String rawname, Attributes atts) throws SAXException
              SAX sax = new SAX();
              ArrayList nodes = sax.getSchemaNodes();
              for(int i = 0; i < nodes.size(); i++)
                   SchemaNode sn = (SchemaNode)nodes.get(i);
                   if(sn.getName().equals(localname))
                        System.out.println(sn.getName() + " = " + lineNo);
         public void endElement(String namespaceURI,String localname,String rawname) throws SAXException
         public void characters(char [] buf,int offset,int len)
              lineNo++;
    }Cheers Alex

  • Java API (web services) for  exportMetadata and importMetadata

    We ususally use WLST command : exportMetadata and importMetadata to export/import MDS. is there any corresponding web services or Java API avalaible for the similar purpose?
    Thanks

    Hi,
    U can expose a EJB or a java class as a webservice in webdynpro and u can use it in webdynpro directly and if u want to use it through Portal u need to create proxies and do it.
    U can go through this weblog which helps u in creating a Bean as a webservice.
    /people/sap.user72/blog/2005/09/15/creating-a-web-service-and-consuming-it-in-web-dynpro
      And u can expose the services created in XI also as webservices.
    Regards,
    Sirisha.

  • How do you create an xsd file for an xml schema in BI Publisher?

    Helllo.
    I hope this is a really daft question for somebody..
    How I create an xsd file to be used as an xml schema to attach to a Data Definition that Ive created? I've obv. got the xml and rtf files ready and attached. I've looked through the relevant docs (XML Publisher Report Designer's Guide.pdf & XML Publisher Administration and Developer's Guide.pdf) but can't find where..
    Once this has been done then I can run the template via ORACLE Financials for the reports I've converted.
    many thanks..
    Steven

    I don't think you need to have an XSD it's an optional field. If you really want to create one use this site: http://www.hitsw.com/xml_utilites/
    I believe I answered your question, don't forget to give me the points.
    Ike Wiggins
    http://bipublisher.blogspot.com

  • Java API - finalize method for XmlResults

    Hello!
    I'm wondering why in DB XML Java code we have a finalize() method which invokes delete() method whereas we are supposed to invoke delete() method manually (according to the documentation). Is it ok if delete() method is invoked twice (it happens in case GC cleans up the XmlResults object) ? Can't we get some problems because of that?
    Thanks,
    Vyacheslav

    Also you should note that Java actually makes no guarantees that the finalize() method is called, and it can frequently happen in practice that this is the case. For instance, the JVM usually doesn't bother calling finalize() on objects if it is shutting down, which can be disastrous for DB XML objects like Environment, XmlManager and XmlContainer, which need to clean up and write data to disk when they are closed. Read the [FAQ | http://www.oracle.com/technology/products/berkeley-db/faq/xml_faq.html#16] for more details.
    John

  • Choosing between SAX & DOM & StringBuffer class for writing XML

    Hii Javaties
    I need to create a XML document from a swing application.
    I need to store this xml in a file.
    For writing XML which parser should i use SAX or DOM or should i go for StringBuffer class.

    I'm not aware of a way to use SAX to create an XML document. It is used to view the contents of an existing XML document or data that is well-structured.
    That leaves you with a choice of DOM or StringBuffer. We cannot tell enought about what you are doing to know which is better. Each has some advantages and disadvantages.
    StringBuffer:
    + less overhead
    - no assistance in ensuring the validity of the result
    + greater control over layout of resulting document (how and when to indent)
    - any control over layout must be done by you.
    DOM (although this task is easier in JDOM)
    - more overhead
    - some learning curve
    + result is guaranteed to be valid XML.
    + there are pretty formatters to generate good looking results
    - there may be layout choices that the standard pretty formatters cannot do
    As an example, consider this part of the Document being created.
    You want <name>John Doe</name>
    With a StringBuffer, you can just add these pieces. With DOM, you need to:
    1) create an Element named "name".
    2) create a Text object with a value of "John Doe".
    3) add the Text object as a child of the Element
    4) add the Element to the parent
    Having done the DOM version (also a JDOM version) several times, I have developed an XMLHelper class that has several static methods to make simple, common constructs.
    It lets me do things like:
    parent.addChild( XmlHelper.makeElement( "name", customerName ) );
    So, the answer to your question is the same as many other questions: It depends.
    Dave Patterson

  • Does Java have any class for linear algebra/matrix computation

    Hi!
    I am new to Java. Would like to ask whether Java provides any class or package for linear algebra/matrix computation, before I switch to MATLAB or write the code by myself.
    Thank you

    Maybe you can find something here,
    http://math.nist.gov/javanumerics/

  • Java A.I. Class for "Doom" game

    Hi for class our group has to make a "doom" like game. and I've been assigned the "A.I" guy
    http://www.vis.uky.edu/~ryang/Teaching/CS335-spr09/proj/CS335%20Final%20Project%20Description.pdf
    for reference (scroll down to A.I.) section
    But the thing Im having trouble...concept wise is like i have to make the A.I. simple and everything....but im referring an an "object" that isn't there.
    Any idea's on where to start
    Ill need like I know a type function (int) so like if the "enemy" see's the player he turns into type 1 and starts chasing, whereas type 0 is just randomly walking around.
    Ill need a die function...of course.
    a Location function, like where on the map they are.
    Some kind of function to recusively walk around (for the "dumb" avatar)
    I just need some ideas?

    ok well I have a "person" class.
    public class Person
            private double UPPER_LEG_SIZE= 0.45;
            private double LOWER_LEG_SIZE= 0.45;
            private double UPPER_ARM_SIZE= 0.4;
            private double LOWER_ARM_SIZE= 0.4;
            private double FOOT_SIZE= 0.2;
            private double HEAD_SIZE= .2;
            private double TORSO_HEIGHT= 0.4;
            private double TORSO_WIDTH= 0.3;
            private double LEG_GIRTH= 0.1;
            private double ARM_GIRTH= 0.05;
            private double HIP_JOINT_SIZE= 0.1;
            private double KNEE_JOINT_SIZE= 0.09;
            private double SHOULDER_JOINT_SIZE= 0.05;
            private double ELBOW_JOINT_SIZE= 0.045;
            private double TORSO_TAPER= 0.7;
            private double STACKS= 10;
            private double SLICES= 10;
            private double NUM_BODY_PARTS= 7;
            private double LEFT= 0;
            private double RIGHT= 1;
            private GL gl;
            private GLUT glut = new GLUT();
            private OBJModel face1_;
            public Person(GL Gl, OBJModel face)
                gl = Gl;
                face1_=face;
                float head_diffuse[] = { 0.7f, 0.7f, 0.0f, 1.0f };
                double torso_diffuse[] = { 0.0, 0.7, 0.7, 1.0 };
                double leg_diffuse[] = { 0.7, 0.0, 0.7, 1.0 };
                double arm_diffuse[] = { 0.7, 0.4, 0.4, 1.0 };
            public void drawPerson()
                gl.glMaterialf(gl.GL_FRONT, gl.GL_AMBIENT_AND_DIFFUSE, .7f);
                drawHead();
                drawTorso();
                drawLeg("left");
                drawLeg("right");
                drawArm("left");
                drawArm("right");
                gl.glColor3f(1.0f, 1.0f, 1.0f);
            public void drawHead()
                gl.glPushMatrix();
                gl.glColor3f(1.0f, 1.0f, 0.0f);
                gl.glTranslatef(0.0f, (float)(TORSO_HEIGHT+(HEAD_SIZE/1.5)), 0.0f);
                face1_.draw(gl);
                gl.glPopMatrix();
            public void drawTorso()
                gl.glPushMatrix();
                gl.glColor3f(0.0f, 1.0f, 1.0f);
                gl.glTranslatef(0.0f, (float)(TORSO_HEIGHT/2.0), 0.0f);
                gl.glScalef((float)TORSO_WIDTH, (float)TORSO_HEIGHT, (float)LEG_GIRTH);
                glut.glutSolidCube(1.0f);
                gl.glPopMatrix();
            public void drawLeg(String side)
                gl.glPushMatrix();
                  if (side.equals("left"))
                    gl.glTranslatef((float)(TORSO_WIDTH/4.0), 0.0f, 0.0f);
                  else
                    gl.glTranslatef((float)(-TORSO_WIDTH/4.0), 0.0f, 0.0f);
                  /* Upper leg: rotates about the x axis only */
                  gl.glColor3f(1.0f, 0.0f, 0.0f);
                  gl.glRotatef(walk(side),1.0f, 0.0f, 0.0f);
                  gl.glPushMatrix();
                  gl.glTranslatef(0.0f, (float)(-UPPER_LEG_SIZE/2.0), 0.0f);
                  gl.glScalef((float)LEG_GIRTH, (float)UPPER_LEG_SIZE, (float)LEG_GIRTH);
                  glut.glutSolidCube(1.0f);
                  gl.glPopMatrix();
                  /* Lower leg: rotates about the x axis only */
                  gl.glColor3f(0.0f, 1.0f, 0.0f);
                  gl.glTranslatef(0.0f, (float)(-(UPPER_LEG_SIZE+LOWER_LEG_SIZE)/2.0), 0.0f);
                  //gl.glRotatef(walk(side), 1.0f, 0.0f, 0.0f);
                  gl.glPushMatrix();
                  gl.glTranslatef(0.0f, (float)(-LOWER_LEG_SIZE/2.0), 0.0f);
                  gl.glScalef((float)LEG_GIRTH, (float)LOWER_LEG_SIZE, (float)LEG_GIRTH);
                  glut.glutSolidCube(1.0f);
                  gl.glPopMatrix();
                  /* Foot: rotates about the x axis only */
                  gl.glColor3f(0.0f, 0.0f, 1.0f);
                  gl.glTranslatef(0.0f, (float)(-(UPPER_LEG_SIZE+LOWER_LEG_SIZE+LEG_GIRTH)/2.0), 0.0f);
                  //gl.glRotatef(Walk_cycle[side][2][Step], 1.0f, 0.0f, 0.0f);
                  gl.glPushMatrix();
                  gl.glTranslatef(0.0f, (float)(-LEG_GIRTH/2.0), (float)(-FOOT_SIZE/4.0));
                  gl.glScalef((float)LEG_GIRTH, (float)LEG_GIRTH, (float)FOOT_SIZE);
                  glut.glutSolidCube(1.0f);
                  gl.glPopMatrix();
                  gl.glPopMatrix();
            public void drawArm(String side)
              gl.glPushMatrix();
              gl.glTranslatef(0.0f, (float)TORSO_HEIGHT, 0.0f);
              if (side.equals("left"))
                  gl.glTranslatef((float)(TORSO_WIDTH/1.5), 0.0f, 0.0f);
              else
                  gl.glTranslatef((float)(-TORSO_WIDTH/1.5), 0.0f, 0.0f);
              /* Upper leg: rotates about the x axis only */
              gl.glColor3f(1.0f, 0.0f, 0.0f);
              if(side.equals("left"))
                gl.glRotatef(75,1.0f, 0.0f, 0.0f);
              gl.glPushMatrix();
              gl.glTranslatef(0.0f, (float)(-UPPER_ARM_SIZE/2.0), 0.0f);
              gl.glScalef((float)ARM_GIRTH, (float)UPPER_ARM_SIZE, (float)ARM_GIRTH);
              glut.glutSolidCube(1.0f);
              gl.glPopMatrix();
              /* Lower leg: rotates about the x axis only */
              gl.glColor3f(0.0f, 1.0f, 0.0f);
              gl.glTranslatef(0.0f, (float)(-(UPPER_ARM_SIZE+LOWER_ARM_SIZE)/2.0), 0.0f);
              //glRotatef(Walk_cycle[arm_which][4][Step], 1.0, 0.0, 0.0);
              gl.glPushMatrix();
              gl.glTranslatef(0.0f, (float)(-LOWER_ARM_SIZE/2.0), 0.0f);
              gl.glScalef((float)ARM_GIRTH, (float)LOWER_ARM_SIZE, (float)ARM_GIRTH);
              glut.glutSolidCube(1.0f);
              gl.glPopMatrix();
              gl.glPopMatrix();
            public float walk(String side)
                if(side.equals("left"))
                    if(Loom.legTimer_==30)
                        Loom.legForward=false;
                    else if(Loom.legTimer_==-30)
                        Loom.legForward=true;
                    if(Loom.legForward==true)
                        Loom.legTimer_++;
                        Loom.leftLegStep_+=5;
                    else
                        Loom.legTimer_--;
                        Loom.leftLegStep_-=5;
                    return (float)Loom.leftLegStep_;
                else
                    if(Loom.legTimer_==30)
                        Loom.legForward=false;
                    else if(Loom.legTimer_==-30)
                        Loom.legForward=true;
                    if(Loom.legForward==true)
                        Loom.legTimer_++;
                        Loom.rightLegStep_-=5;
                    else
                        Loom.legTimer_--;
                        Loom.rightLegStep_+=5;
                    return (float)Loom.rightLegStep_;
        }

  • Generation of java classes from XML Schema.

    Hi All,
    I am working with JWSDP-2.0 but got stucked.:
    To generate Java classes from an XML Schema with the JAXB ,I need to have following jar file in thils location with this JWSDP-2.0
    <JWSDP>/jaxb/lib/jaxb-api.jar
    <JWSDP>/jaxb/lib/jaxb-impl.jar
    <JWSDP>/jaxb/lib/jaxb-libs.jar
    <JWSDP>/jaxb/lib/jaxb-xjc.jar
    <JWSDP>/jwsdp-shared/lib/namespace.jar
    <JWSDP>/jwsdp-shared/lib/jax-qname.jar
    <JWSDP>/jwsdp-shared/lib/relaxngDatatype.jar
    And here I m not finding as jaxb-libs.jar,namespace.jar and jax-qname.jar on respective location.
    If I m putting these left jar file from another place it is not generating all the classes as at least in number it should be 45 but it is generating merely 5 classes.
    Can any one help me regarding this.
    Regards.
    Shelly.

    These JAXB JAR files are for JAXB 1.0.
    For JAXB 2.0 the following JAR files are required.
    C:\Sun\jwsdp-2.0\jaxb\lib\jaxb-api.jar
    C:\Sun\jwsdp-2.0\jaxb\lib\jaxb-impl.jar
    C:\Sun\jwsdp-2.0\jaxb\lib\jaxb-xjc.jar
    C:\Sun\jwsdp-2.0\jwsdp-shared\lib\activation.jar
    C:\Sun\jwsdp-2.0\sjsxp\lib\jsr173_api.jar
    C:\Sun\jwsdp-2.0\sjsxp\lib\sjsxp.jar

  • BUILD FAILED java.lang.Error: unable to load schema-for-schema for W3C XML

    I am new to JAXB, I am trying to run the sample applciations on Win 98,
    I have set up the environment values as per the UserGuide specs.
    I am getting the following error:
    BUILD FAILED java.lang.Error: unable to load schema-for-schema for W3C XML Schema at com.sun.msv.reader.xmlschema.XMLSchemaReader.getXmlSchemaForXmlSchema (XMLSchemaReader.java:190)
    Could someone please suggest a solution.
    Thank you.

    Hi
    I am using Windows 2000 and I am repeatedly getting the same error too (See below). Would appreciate any help ..
    parsing a schema...
    org.iso_relax.verifier.VerifierConfigurationException
         at com.sun.msv.verifier.jarv.FactoryImpl.compileSchema(FactoryImpl.java:104)
         at org.iso_relax.verifier.VerifierFactory.compileSchema(Unknown Source)
         at org.iso_relax.verifier.VerifierFactory.compileSchema(Unknown Source)
         at com.sun.msv.reader.xmlschema.XMLSchemaReader.getXmlSchemaForXmlSchema(XMLSchemaReader.java:186)
         at com.sun.tools.xjc.Driver$1.<init>(Driver.java:477)
         at com.sun.tools.xjc.Driver.loadXMLSchemaGrammar(Driver.java:476)
         at com.sun.tools.xjc.Driver.loadGrammar(Driver.java:404)
         at com.sun.tools.xjc.Driver.run(Driver.java:268)
         at com.sun.tools.xjc.Driver.main(Driver.java:88)
         at sample1.Binder.main(Binder.java:18)
    StackTrace of Original Exception:
    java.lang.NullPointerException
         at com.sun.msv.datatype.xsd.TypeIncubator.addFacet(TypeIncubator.java:64)
         at com.sun.msv.reader.datatype.xsd.XSDatatypeExp$1.addFacet(XSDatatypeExp.java:87)
         at com.sun.msv.reader.datatype.xsd.FacetState.startSelf(FacetState.java:56)
         at com.sun.msv.reader.State.init(State.java:154)
         at com.sun.msv.reader.GrammarReader.pushState(GrammarReader.java:579)
         at com.sun.msv.reader.datatype.xsd.TypeState.startElement(TypeState.java:101)
         at org.xml.sax.helpers.XMLFilterImpl.startElement(Unknown Source)
         at org.apache.xerces.parsers.AbstractSAXParser.startElement(AbstractSAXParser.java:459)
         at org.apache.xerces.parsers.AbstractXMLDocumentParser.emptyElement(AbstractXMLDocumentParser.java:221)
         at org.apache.xerces.impl.XMLNamespaceBinder.handleStartElement(XMLNamespaceBinder.java:874)
         at org.apache.xerces.impl.XMLNamespaceBinder.emptyElement(XMLNamespaceBinder.java:591)
         at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElement(XMLDocumentFragmentScannerImpl.java:747)
         at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1477)
         at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:329)
         at org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:525)
         at org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:581)
         at org.apache.xerces.parsers.XMLParser.parse(XMLParser.java:152)
         at org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1175)
         at com.sun.msv.reader.GrammarReader._parse(GrammarReader.java:459)
         at com.sun.msv.reader.GrammarReader.switchSource(GrammarReader.java:434)
         at com.sun.msv.reader.GrammarReader.switchSource(GrammarReader.java:407)
         at com.sun.msv.reader.xmlschema.XMLSchemaReader.switchSource(XMLSchemaReader.java:683)
         at com.sun.msv.reader.xmlschema.ImportState.startSelf(ImportState.java:41)
         at com.sun.msv.reader.State.init(State.java:154)
         at com.sun.msv.reader.GrammarReader.pushState(GrammarReader.java:579)
         at com.sun.msv.reader.SimpleState.startElement(SimpleState.java:72)
         at org.xml.sax.helpers.XMLFilterImpl.startElement(Unknown Source)
         at org.apache.xerces.parsers.AbstractSAXParser.startElement(AbstractSAXParser.java:459)
         at org.apache.xerces.impl.XMLNamespaceBinder.handleStartElement(XMLNamespaceBinder.java:877)
         at org.apache.xerces.impl.XMLNamespaceBinder.startElement(XMLNamespaceBinder.java:569)
         at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElement(XMLDocumentFragmentScannerImpl.java:759)
         at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1477)
         at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:329)
         at org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:525)
         at org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:581)
         at org.apache.xerces.parsers.XMLParser.parse(XMLParser.java:152)
         at org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1175)
         at com.sun.msv.reader.GrammarReader._parse(GrammarReader.java:459)
         at com.sun.msv.reader.GrammarReader.parse(GrammarReader.java:449)
         at com.sun.msv.reader.xmlschema.XMLSchemaReader.parse(XMLSchemaReader.java:89)
         at com.sun.msv.verifier.jarv.XSFactoryImpl.parse(XSFactoryImpl.java:26)
         at com.sun.msv.verifier.jarv.FactoryImpl.compileSchema(FactoryImpl.java:95)
         at org.iso_relax.verifier.VerifierFactory.compileSchema(Unknown Source)
         at org.iso_relax.verifier.VerifierFactory.compileSchema(Unknown Source)
         at com.sun.msv.reader.xmlschema.XMLSchemaReader.getXmlSchemaForXmlSchema(XMLSchemaReader.java:186)
         at com.sun.tools.xjc.Driver$1.<init>(Driver.java:477)
         at com.sun.tools.xjc.Driver.loadXMLSchemaGrammar(Driver.java:476)
         at com.sun.tools.xjc.Driver.loadGrammar(Driver.java:404)
         at com.sun.tools.xjc.Driver.run(Driver.java:268)
         at com.sun.tools.xjc.Driver.main(Driver.java:88)
         at sample1.Binder.main(Binder.java:18)
    java.lang.Error: unable to load schema-for-schema for W3C XML Schema
         at com.sun.msv.reader.xmlschema.XMLSchemaReader.getXmlSchemaForXmlSchema(XMLSchemaReader.java:190)
         at com.sun.tools.xjc.Driver$1.<init>(Driver.java:477)
         at com.sun.tools.xjc.Driver.loadXMLSchemaGrammar(Driver.java:476)
         at com.sun.tools.xjc.Driver.loadGrammar(Driver.java:404)
         at com.sun.tools.xjc.Driver.run(Driver.java:268)
         at com.sun.tools.xjc.Driver.main(Driver.java:88)
         at sample1.Binder.main(Binder.java:18)
    Exception in thread "main"
    -Thanks
    Guna

Maybe you are looking for

  • Apex Listener 2.0.1 vs Sql Developer Administration 3.2.20.09 bugs

    Apex Listener 2.0.1 / Sql Developer 3.2.20.09 / Apex 4.1.1 1. I'm using basic connection type with service name. Each time I connect to listener administration it is resetted to SID with default name as orcl. 2. Test Settings does not work in case ho

  • Annoying Little Blinking Hand Cursor

    I'm not sure where it came from, but I've noticed the last few days that I suddenly have this blinking hand/arrow cursor when I'm online. I thought it was just on one site, but it isn't; it shows up everywhere. I've run AVG; it doesn't pick up anythi

  • Installation problems - Vise software probs + Other problems with 10.4.11

    I've posted elsewhere on the forum about this but wanted to try another tack. I have recently hit the automatic update button (having left it a year) when promted and let the Mac go and get the updates - including a firmware update. Then the problems

  • Dekorator from AUR problems

    Hello, am trying to get deKorator 0.3 to work, ive got it installed from the AUR. Well, ive changed the source/server in PKGBUILD manually, because the one that was in there didnt work, but that shouldnt be the problem i think, coz its just the same

  • Unable to automatically install Flash 12 over Flash 11 via GPO Software Installation

    We have a GPO software installation to install Flash 12 to a group of Windows 7 64-bit workstations. It works fine on a system that has no previous version of Flash already installed, but when the workstation has Flash 11 installed, the installation