Maximum # of arguments for a method

Is there a maximum # of arguments for a method?
I have the following signature for a method:
void process_l1_queue(int processnum, Scheduler level1[], Scheduler[] level2[], Scheduler[] level3[],Scheduler[] level4[],int index,int l2,int l3,int l4)when I call it with the following statement,
level1.process_l1_queue(process_count, level1,level2,level3,level4,l1ptr, l2ptr, l3ptr,l4ptr);
I get a cannot resolve symbol error pointing at the comma after l3ptr.
I've deleted the l4ptr and the same error points to the ).

wow. People can often be a bit too inflammatory with their replies here, but, at the risk of sounding like so, I would fire you on the spot if you develop an application class with that signature. There is no defense for such a signature- put some of those arguments in the constructor (this instance will always be of a certain calendar type, dollar currency), subclass- divide the functionality into smaller units. That signature is too complex and it will make every thing more difficult, particularly if some one else has to manage the code in the future. I would say, as a general rule, if you find yourself asking, will java let me put some thing this mammoth in it the way I intend, you're often using a poor design. All things being equal, you shouldn't normally have to test the limits of the JLS.

Similar Messages

  • Default argument for main method

    Dear All,
    What default value will be supplied to main method incase we are not sending any argument from command Line..
    Rgrds
    Ravi. N

    > this indicates that we can invoke a main method
    without passing any actual argumnets
    [EDIT] Only in the case of varargs, which you can declare your methods with, if you wish.
    Example:class Foo {      
        public static void main(String[] args) {
            // Bar.main();  <--- won't compile
            Baz.main();
    class Bar {
        public static void main(String[] args) { }
    class Baz {
        public static void main(String... args) { }
    }~

  • Generic arguments in a Method on an interface.

    Hi all,
    I'm having trouble with the following code:
    Basically this is what i want:
    the Classes:
    public class SuperClass
    public class ClassA extends SuperClass
    public class ClassB extends SuperClass
    public class ClassC extends SuperClass
    The interface
    public interface interfaceX
       public methodX(SuperClass A);
    Implementation of the interface
    public class classX implements interfaceX
         public methodX(ClassA A)
    }My problem is on the declaration of the interface interfaceX in the class classX.
    How can i do such thing?
    I'm trying to avoid the "correct" declaration. this is:
    public methodX(SuperClass A)
            { ... }because I have a couple of class that extends that interface with deferents arguments, all of them extending from the SuperClass.
    I know i could use the instanceof keywork, but i'm trying to avoid the extra checking...
    Thanks in advance for any help!!
    Edited by: ValdemarP on Mar 29, 2010 1:55 AM

    i know I'm changing the contract, but only the arguments. if you notice, the new arguments is child of class SuperClass... How can I do this? Declare an method in an interface that accepts an arguments of some class and implement that interface, with argument that are children of the arguments declared in the interface... hope i was more clear this time... :(
    Example. I can do this on an interface:
    public void MethodListGeneric(List<? extends SuperClass> xpto )and during the implementation of the interface, I can declare the method using any arguments for the generic list, that extends SuperClass.
    Example:
    public class xpto extends InterfaceX
        public void MethodListGeneric(List<ClassA> xpto )
         // in here I've use ClassA insted of SuperClass
    }Edited by: ValdemarP on Mar 29, 2010 3:15 AM
    Edited by: ValdemarP on Mar 29, 2010 3:15 AM

  • Java.lang.VerifyError - Incompatible object argument for function call

    Hi all,
    I'm developing a JSP application (powered by Tomcat 4.0.1 in JDK 1.3, in Eclipse 3.3). Among other stuff I have 3 classes interacting with an Oracle database, covering 3 use cases - renaming, adding and deleting an database object. The renaming class simply updates the database with a String variable it receives from the request object, whereas the other two classes perform some calculations with the request data and update the database accordingly.
    When the adding or deleting classes are executed, by performing the appropriate actions through the web application, Tomcat throws the following:
    java.lang.VerifyError: (class: action/GliederungNewAction, method: insertNewNode signature: (Loracle/jdbc/driver/OracleConnection;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;I)V) Incompatible object argument for function call
         at java.lang.Class.forName0(Native Method)
         at java.lang.Class.forName(Class.java:120)
         at action.ActionMapping.perform(ActionMapping.java:53)
         at ControllerServlet.doResponse(ControllerServlet.java:92)
         at ControllerServlet.doPost(ControllerServlet.java:50)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
    ...The renaming works fine though. I have checked mailing lists and forums as well as contacted the company's java support but everything I have tried out so far, from exchanging the xerces.jar files found in JDOM and Tomcat to rebuidling the project didn't help.
    I just can't explain to myself why this error occurs and I don't see how some additional Java code in the other 2 classes could cause it?
    I realize that the Tomcat and JDK versions I'm using are totally out of date, but that's company's current standard and I can't really change that.
    Here's the source code. I moved parts of the business logic from Java to Oracle recently but I left the SQL statements that the Oracle stored procedures are executing if it helps someone.
    package action;
    import java.sql.CallableStatement;
    import java.sql.PreparedStatement;
    import java.sql.ResultSet;
    import java.sql.SQLException;
    import java.util.StringTokenizer;
    import javax.servlet.http.HttpServletRequest;
    import javax.servlet.http.HttpServletResponse;
    import javax.servlet.http.HttpSession;
    import oracle.jdbc.driver.OracleConnection;
    * This class enables the creation and insertion of a new catalogue node. A new node
    * is always inserted as the last child of the selected parent node.
    public class GliederungNewAction implements Action {
         public String perform(ActionMapping mapping, HttpServletRequest request,
                   HttpServletResponse response) {
              // fetch the necessary parameters from the JSP site
              // the parent attribute is the selected attribute!
              String parent_attribute = request.getParameter("attr");
              String catalogue = request.getParameter("catalogue");
              int parent_sequenceNr = Integer.parseInt(request.getParameter("sort_sequence"));
              // connect to database    
              HttpSession session = request.getSession();   
              db.SessionConnection sessConn = (db.SessionConnection) session.getAttribute("connection");
              if (sessConn != null) {
                   try {
                        sessConn.setAutoCommit(false);
                        OracleConnection connection = (OracleConnection)sessConn.getConnection();
                        int lastPosition = getLastNodePosition( getLastChildAttribute(connection, catalogue, parent_attribute) );
                        String newNodeAttribute = createNewNodeAttribute(parent_attribute, lastPosition);
                        // calculate the sequence number
                        int precedingSequenceNumber = getPrecedingSequenceNumber(connection, catalogue, parent_attribute);
                        if ( precedingSequenceNumber == -1 ) {
                             precedingSequenceNumber = parent_sequenceNr;
                        int sortSequence = precedingSequenceNumber + 1;
                        setSequenceNumbers(connection, catalogue, sortSequence);
                        // insert the new node into DB
                        insertNewNode(connection, catalogue, newNodeAttribute, parent_attribute, "Neuer Punkt", sortSequence);
                        connection.commit();
                   } catch(SQLException ex) {
                        ex.printStackTrace();
              return mapping.getForward();
          * Creates, fills and executes a prepared statement to insert a new entry into the specified table, representing
          * a new node in the catalogue.
         private void insertNewNode(OracleConnection connection, String catalogue, String attribute, String parent_attribute, String description, int sortSequence) {
              try {
                   String callAddNode = "{ call fasi_lob.pack_gliederung.addNode(:1, :2, :3, :4, :5) }";
                   CallableStatement cst;
                   cst = connection.prepareCall(callAddNode);
                   cst.setString(1, catalogue);
                   cst.setString(2, attribute);
                   cst.setString(3, parent_attribute);
                   cst.setString(4, description);
                   cst.setInt(5, sortSequence);
                   cst.execute();
                   cst.close();
              } catch (SQLException e1) {
                   // TODO Auto-generated catch block
                   e1.printStackTrace();
    //          String insertNewNode = "INSERT INTO vstd_media_cat_attributes " +
    //                    "(catalogue, attribute, parent_attr, description, sort_sequence) VALUES(:1, :2, :3, :4, :5)";
    //          PreparedStatement insertStmt;
    //          try {
    //               insertStmt = connection.prepareStatement(insertNewNode);
    //               insertStmt.setString(1, catalogue);
    //               insertStmt.setString(2, attribute);
    //               insertStmt.setString(3, parent_attribute);
    //               insertStmt.setString(4, description);
    //               insertStmt.setInt(5, sortSequence);
    //               insertStmt.execute();
    //               insertStmt.close();
    //          } catch (SQLException e) {
    //               e.printStackTrace();
          * This method returns the attribute value of the last child of the parent under which
          * we want to insert a new node. The result set is sorted in descending order and only the
          * first result (that is, the last child under this parent) is fetched.
          * If the parent node has no children, "parent_attr.0" is returned. 
          * @param connection
          * @param catalogue
          * @param parent_attribute
          * @return attribute of the last child under this parent, or "parent_attr.0" if parent has no children
         private String getLastChildAttribute(OracleConnection connection, String catalogue, String parent_attribute) {
              String queryLastChild = "SELECT attribute FROM vstd_media_cat_attributes " +
                                            "WHERE catalogue=:1 AND parent_attr=:2 ORDER BY sort_sequence DESC";
              String lastChildAttribute;
              PreparedStatement ps;
              try {
                   ps = connection.prepareStatement(queryLastChild);
                   ps.setString(1, catalogue);
                   ps.setString(2, parent_attribute);
                   ResultSet rs = ps.executeQuery();
                   /* If a result is returned, the selected parent already has children.
                    * If not set the lastChildAttribute to parent_attr.0
                   if (rs.next()) {
                        lastChildAttribute = rs.getString("attribute");
                   } else {
                        lastChildAttribute = parent_attribute.concat(".0");
                   rs.close();
                   return lastChildAttribute;
              } catch (SQLException e) {
                   e.printStackTrace();
                   return null;
          * This helper method determines the position of the last node in the attribute.
          * i.e for 3.5.2 it returns 2, for 2.1 it returns 1 etc.
          * @param attribute
          * @return position of last node in this attribute
         private int getLastNodePosition(String attribute) {
              StringTokenizer tokenizer = new StringTokenizer(attribute, ".");
              String lastNodePosition = "0";
              while( tokenizer.hasMoreTokens() ) {
                   lastNodePosition = tokenizer.nextToken();
              return Integer.parseInt(lastNodePosition);
          * This method calculates the attribute of a node being inserted
          * by incrementing the last child position by 1 and attaching the
          * incremented position to the parent.
          * @param parent_attr
          * @param lastPosition
          * @return attribute of the new node
         private String createNewNodeAttribute(String parent_attr, int lastPosition) {
              String newPosition = new Integer(lastPosition + 1).toString();
              return parent_attr.concat("." + newPosition);
          * This method checks if the required sequence number for a new node is already in use and
          * handles the sequence numbers accordingly.
          * If the sequence number for a new node is NOT IN USE, the method doesn't do anything.
          * If the sequence number for a new node is IN USE, the method searches for the next free
          * sequence number by incrementing the number by one and repeating the query until no result
          * is found. Then all the sequence numbers between the required number (including, >= relation)
          * and the nearest found free number (not including, < relation) are incremented by 1, as to
          * make space for the new node.
          * @param connection
          * @param catalogue
          * @param newNodeSequenceNumber required sequence number for the new node
         private void setSequenceNumbers(OracleConnection connection, String catalogue, int newNodeSequenceNumber) {
              // 1. check if the new sequence number exists - if no do nothing
              // if yes - increment by one and see if exists
              //           repeat until free sequence number exists
              // when found increment all sequence numbers freeSeqNr > seqNr >= newSeqNr
              String query = "SELECT sort_sequence FROM vstd_media_cat_attributes " +
                        "WHERE catalogue=:1 AND sort_sequence=:2";
              PreparedStatement ps;
              try {
                   ps = connection.prepareStatement(query);
                   ps.setString(1, catalogue);
                   ps.setInt(2, newNodeSequenceNumber);               
                   ResultSet rs = ps.executeQuery();
                   // if no result, the required sequence number is free - nothing to do
                   if( rs.next() ) {
                        int freeSequenceNumber = newNodeSequenceNumber;
                        do {
                             ps.setString(1, catalogue);
                             ps.setInt(2, freeSequenceNumber++);
                             rs = ps.executeQuery();
                        } while( rs.next() );
                        // increment sequence numbers - call stored procedure
                        String callUpdateSeqeunceNrs = "{ call fasi_lob.pack_gliederung.updateSeqNumbers(:1, :2, :3) }";
                        CallableStatement cst = connection.prepareCall(callUpdateSeqeunceNrs);
                        cst.setString(1, catalogue);
                        cst.setInt(2, newNodeSequenceNumber);
                        cst.setInt(3, freeSequenceNumber);
                        cst.execute();
                        cst.close();
    //                    String query2 = "UPDATE vstd_media_cat_attributes " +
    //                                      "SET sort_sequence = (sort_sequence + 1 ) " +
    //                                      "WHERE catalogue=:1 sort_sequnce >=:2 AND sort_sequence <:3";
    //                    PreparedStatement ps2;
    //                    ps2 = connection.prepareStatement(query2);
    //                    ps2.setString(1, catalogue);
    //                    ps2.setInt(2, newNodeSequenceNumber);
    //                    ps2.setInt(3, freeSequenceNumber);
    //                    ps.executeUpdate();
    //                    ps.close();
                   } // end of if block
                   rs.close();
              } catch (SQLException e) {
                   e.printStackTrace();
          * This method finds the last sequence number preceding the sequence number of a node
          * that is going to be inserted. The preceding sequence number is required to calculate
          * the sequence number of the new node.
          * We perform a hierarchical query starting from the parent node: if a result is returned,
          * we assign the parent's farthest descendant's node sequence number; if no result
          * is returned, we assign the parent's sequence number.
          * @param connection
          * @param catalogue
          * @param parent_attr parent attribute of the new node
          * @return
         private int getPrecedingSequenceNumber(OracleConnection connection, String catalogue, String parent_attr) {
              int sequenceNumber = 0;
              String query = "SELECT sort_sequence FROM vstd_media_cat_attributes " +
                                "WHERE catalogue=:1 " +
                                "CONNECT BY PRIOR attribute = parent_attr START WITH parent_attr=:2 " +
                                "ORDER BY sort_sequence DESC";
              try {
                   PreparedStatement ps = connection.prepareStatement(query);
                   ps.setString(1, catalogue);
                   ps.setString(2, parent_attr);
                   ResultSet rs = ps.executeQuery();
                   if ( rs.next() ) {
                        sequenceNumber = rs.getInt("sort_sequence");
                   } else {
                        // TODO: ggf fetch from request!
                        sequenceNumber = -1;
                   rs.close();
                   ps.close();
              } catch (SQLException e) {
                   e.printStackTrace();
              return sequenceNumber;
    }

    After further googling I figured out what was causing the problem: in eclipse I was referring to external libraries located in eclipse/plugins directory, whereas Tomcat was referring to the same libraries (possibly older versions) in it's common/lib directory.

  • Maximum line size for OO ALV

    Hi,
    1) What is the maximum line size for OO ALV?
    Or in the other way round, how is the maximum column size for OO ALV when i using the method below:
      DATA: r_grid TYPE REF TO cl_salv_form_layout_grid.
      CREATE OBJECT r_grid.
      r_grid->create_text(
          row     = 2
          column  = 2
          text    = sy-mandt ).
    2) Another question, how to change the below time format:
    223801 -> 22:38:01?
    When I try to use sy-uzeit to display the header in ALV like below:
      CREATE OBJECT r_grid.
      r_grid->create_text(
          row     = 2
          column  = 2
          text    = sy-uzeit ).
    The ALV will be displaying 223801. How i can convert to format 22:38:01 and display it in ALV?
    Thanks.

    Hi,
    For your second qn.,try by declaring an extra field of type character of length 10 in the structure you are using for ALV.
    After that ,after you appended the records,just try the follg...
    loop at itab into wa.
    concatenate f10(2) ':' f12(2) ':' f1+4(2) into f2.
    modify itab from wa transporting f2 index sy-tabix.
    endloop.

  • Too many arguments for stored procedure call

    I have a stored procedure with 34 arguments, including the return value. I am trying to call it from java using JDBC thin drivers (jdk11, oracle815), but I get the "wrong number or types of arguments" error message. JDBC-OCI fails also. I saw a reference in this discussion group to there being a limit of 32 arguments for stored procedure calls from jdbc (posted 6/29/99). Is there such a limit? If so, is there a fix or workaround? If there is not a limit, how can I determine which argument is causing the problem?
    Many thanks.
    Mike
    java.sql.SQLException: ORA-06550: line 1, column 13:
    PLS-00306: wrong number or types of arguments in call to 'PUT_CHECK'
    ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored
    at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java)
    at oracle.jdbc.ttc7.Oall7.receive(Oall7.java)
    at oracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java)
    at oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java)
    at oracle.jdbc.driver.OracleStatement.doExecuteOther(OracleStatement.jav
    a)
    at oracle.jdbc.driver.OracleStatement.doExecuteWithBatch(OracleStatement
    .java)
    at oracle.jdbc.driver.OracleStatement.doExecute(OracleStatement.java)
    at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStateme
    nt.java)
    at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePrepar
    edStatement.java)
    at oracle.jdbc.driver.OraclePreparedStatement.execute(OraclePreparedStat
    ement.java)
    at metris.quickcheck.database.DS1.main(DS1.java:79)
    null

    I must confess I still don't understand your problem. By rows ...
    I have an sql that recodes a column and has 1450 rows. This doesn't work
    although when I use the same with less rows 40-60 it works.... do you mean rows in the table or elements in the CASE() statement ?
    From the 9i SQL Reference:
    " The maximum number of arguments in a CASE expression is 255, and each WHEN ... THEN pair counts as two arguments. To avoid exceeding the limit of 128 choices, you can nest CASE expressions. That is return_expr can itself be a CASE expression."
    According to the 10g docs the limit is the same there.
    Cheers, APC

  • Problem with cesession.jar: Incompatible object argument for function call

    Hi,
    I'm looking for an actual file cesession.jar because my current version from BOXI SP2 (01.03.2007 09:22, 62 KB) causes an error.
    Who can help me?
    Best Regards
    Arnold
    type Exception report
    message
    description The server encountered an internal error () that prevented it from fulfilling this request.
    exception
    org.apache.jasper.JasperException: (class: com/crystaldecisions/sdk/framework/internal/d, method: a signature: ()V) Incompatible object argument for function call
         org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:460)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:355)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    root cause
    javax.servlet.ServletException: (class: com/crystaldecisions/sdk/framework/internal/d, method: a signature: ()V) Incompatible object argument for function call
         org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:841)
         org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:774)
         org.apache.jsp.TutorialDesktop.start_jsp._jspService(start_jsp.java:151)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:331)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    root cause
    java.lang.VerifyError: (class: com/crystaldecisions/sdk/framework/internal/d, method: a signature: ()V) Incompatible object argument for function call
         com.crystaldecisions.sdk.framework.internal.CEFactory.makeSessionMgr(Unknown Source)
         com.crystaldecisions.sdk.framework.CrystalEnterprise.getSessionMgr(Unknown Source)
         org.apache.jsp.TutorialDesktop.start_jsp.createAuthenticationList(start_jsp.java:26)
         org.apache.jsp.TutorialDesktop.start_jsp._jspService(start_jsp.java:132)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:331)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    note The full stack trace of the root cause is available in the Apache Tomcat/5.5.26 logs.

    Hello Arnold,
    Can you provide us the exact information about the implementation version and Ant-version of the cesession.jar file that you are using.
    This could be observed by opening the jar file using winrar or winzip, then go to the MANIFEST.MF file present inside META-INF folder.
    Once you will open the MANIFEST.MF file, please let us know the first seven lines present inside the same fle.
    Thanks,
    Chinmay

  • What is the Arguement for getFailureStepLog() Method?

    I'm not that good with Java, so I'm not sure but oracle has a slew of information on different Java Methods for ODI and getting information from the Repository. But I don't see any information on what the Argument is for these methods.
    For example, I can build a Refreshing Variable to get the Session Number:
    SELECT <%=odiRef.getSession("SESS_NO")%> FROM DUAL
    The Arguments for the odiRef.getSession() are listed in the KM Dev Guide.
    However all the online oracle pages do not list the Arguments?? Like below:
    http://docs.oracle.com/cd/E21764_01/apirefs.1111/e17060/oracle/odi/domain/runtime/session/OdiSession.html#getFailureStepLog__

    Why do you think it needs an argument to return ?
    Return the step log (OdiSessionStepLog) that caused the session's failure. If the session didn't failed, than method will always return null. However, it can be null even if session is failed (e.g. session failed at preparation time).
    It takes session id automatically from failed step.

  • Inputting multiple arguments into a method

    Hi,
    I have somewhat of a problem. I'm trying to create a method, stringQuery, and I do not know how many arguments the method will take.
    Allow me to explain my goal, so you can have some idea of what I'm talking about.
    I want to create a method that will basically generate a SQL query (no, this is NOT a JDBC question) from text. This method should be able to take a large number of String arguments, because the user might want to select one thing from the database, or he or she might want to select five things, or he or she might want to select twenty things.
    Because of this, there is not a set number of arguments for my stringQuery method.
    Furthermore, the method should also be able to take a large number of float arguments, in case the user wants to specify where he or she is selecting data from.
    It's just a mess, I'm not sure where to start, and I'm pretty damn sure there must be a better way. I can specify that I want an infinite number of Strings by saying something like this:
    public static String stringQuery(String... select)But I cannot do the same for floats, or for another String array. Or can I? If I try to do something like:
    public static String stringQuery(String... select, float... foo)I get a syntax error, that says "select must be the last parameter". If I change the order, it will say "foo must be the last parameter", obviously. Therefore, I can't do that.
    I realize this is a lot of information. However, if someone could please point me in the right direction here (either how to do what I am trying to do, or a better method for what I am trying to do), I would be very appreciative.
    Also, please let me know if this didn't make much sense, and what part of it didn't make sense.
    Thanks,
    Dan

    I'm not too sure what you mean by this. Do you know
    of any links or resources that can explain this
    further?Search for "Object-Oriented Programming".public class SQLBuilder {
      private // some list of selection criteria
      public SQLBuilder() {
        // initialize the list to empty
      public void addCriterion(String name, String value) {
        // add this criterion to the list
      public void addCriterion(String name, int value) {
        // add this criterion to the list
      // many more overloaded addCriterion methods could go here
      public String toString() {
        // compute the SQL string based on the list
    }And to use that:SQLBuilder builder = new SQLBuilder();
    builder.addCriterion("name", "Arthur Eddington");
    builder.addCriterion("answer", 137);
    String query = builder.toString();

  • [Tomcat] Incompatible object argument for function call

    Hello,
    I've got a jsp which use a DOM parser to read XML. This jsp works good on my station :
    Tomcat 4.1.24
    JDK 1.3.1_07
    Windows XP
    I put my webapp on another station :
    Tomcat 4.1.24 (the same)
    JDK 1.3.1_12
    Windows NT
    but there, my jsp return an error :
    java.lang.VerifyError: (class: org/apache/jsp/doFncaBourse_jsp, method: _jspService signature: (Ljavax/servlet/http/HttpServletRequest;Ljavax/servlet/http/HttpServletResponse;)V) Incompatible object argument for function call
    at java.lang.Class.newInstance0(Native Method)
    at java.lang.Class.newInstance(Class.java:232)
    at org.apache.jasper.servlet.JspServletWrapper.getServlet(JspServletWrapper.java:151)
    at org.apache.jasper.compiler.Compiler.isOutDated(Compiler.java:440)
    at org.apache.jasper.compiler.Compiler.isOutDated(Compiler.java:390)
    at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:471)
    at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:190)
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295)
    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:256)
    at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
    at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
    at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2422)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)
    at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
    at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:171)
    at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:163)
    at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)
    at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
    at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:199)
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:828)
    at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:700)
    at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:584)
    at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
    at java.lang.Thread.run(Thread.java:479)
    I don't understand where it comes from so if somebody can help me, it will be wonderful.
    Thanks et good afternoon and sorry for my english.

    Is it enough to write
    set JAVA_OPT= "-noverify"
    before
    set EXECJAVA=%RUNJAVA%
    set MAINCLASS=org.apache.catalina.startup.Bootstrap
    set ACTION=start
    set SECURITY_POLICY_FILE=
    set DEBUG_OPTS=
    set JPDA=
    ?

  • Incompatible object argument for function call exception

    I am hoping someone has seen this issue before.
    Running CF 7.0.1.116466 with JRun 4.
    I have a 3rd party search engine application running on a
    separate server. I interface with the engine via their Java API. I
    am able to use the search engine when executing using a home grown
    Java application. It also worked with CF 6. However, when I try to
    implement the same cold in CF, it fails with the exception attached
    below. I am able to successfully create the objects. The error
    occurs when the objects attempt to connect with the engine.
    I have also attached the code that is causing the errors.
    "seObj" creates an interface with the search engine. It is
    constructed with the server address as a parameter. It does not
    attempt to contact the engine when it is first constructed.
    "dsObj" allows access to specific content in the engine. This
    is where the connection to the engine is attempted and the error
    occurs.
    Any assistance would be greatly appreciated.
    12/13 10:26:12 error (class: org/jacorb/orb/Delegate, method:
    getReference signature:
    (Lorg/jacorb/poa/POA;)Lorg/omg/CORBA/portable/ObjectImpl;)
    Incompatible object argument for function call
    java.lang.VerifyError: (class: org/jacorb/orb/Delegate,
    method: getReference signature:
    (Lorg/jacorb/poa/POA;)Lorg/omg/CORBA/portable/ObjectImpl;)
    Incompatible object argument for function call
    at org.jacorb.orb.ORB._getObject(Unknown Source)
    at org.jacorb.orb.ORB.string_to_object(Unknown Source)
    at com.engenium.semetric.Engine.initRef(Engine.java:731)
    at com.engenium.semetric.Engine.getDocSet(Engine.java:81)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
    Method)
    at
    sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at
    sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:324)
    at
    coldfusion.runtime.java.JavaProxy.invoke(JavaProxy.java:74)
    at coldfusion.runtime.CfJspPage._invoke(CfJspPage.java:1634)
    at cfinsert2ecfm673131553.runPage(C:\Documents and
    Settings\Jameso\My Documents\workspace\SemetricCF7\insert.cfm:12)
    at coldfusion.runtime.CfJspPage.invoke(CfJspPage.java:152)
    at
    coldfusion.tagext.lang.IncludeTag.doStartTag(IncludeTag.java:349)
    at
    coldfusion.filter.CfincludeFilter.invoke(CfincludeFilter.java:65)
    at
    coldfusion.filter.ApplicationFilter.invoke(ApplicationFilter.java:210)
    at
    coldfusion.filter.RequestMonitorFilter.invoke(RequestMonitorFilter.java:51)
    at coldfusion.filter.PathFilter.invoke(PathFilter.java:86)
    at
    coldfusion.filter.LicenseFilter.invoke(LicenseFilter.java:27)
    at
    coldfusion.filter.ExceptionFilter.invoke(ExceptionFilter.java:69)
    at
    coldfusion.filter.BrowserDebugFilter.invoke(BrowserDebugFilter.java:52)
    at
    coldfusion.filter.ClientScopePersistenceFilter.invoke(ClientScopePersistenceFilter.java:2 8)
    at
    coldfusion.filter.BrowserFilter.invoke(BrowserFilter.java:38)
    at
    coldfusion.filter.GlobalsFilter.invoke(GlobalsFilter.java:38)
    at
    coldfusion.filter.DatasourceFilter.invoke(DatasourceFilter.java:22)
    at
    coldfusion.filter.RequestThrottleFilter.invoke(RequestThrottleFilter.java:115)
    at coldfusion.CfmServlet.service(CfmServlet.java:107)
    at
    coldfusion.bootstrap.BootstrapServlet.service(BootstrapServlet.java:78)
    at
    jrun.servlet.ServletInvoker.invoke(ServletInvoker.java:91)
    at
    jrun.servlet.JRunInvokerChain.invokeNext(JRunInvokerChain.java:42)
    at
    jrun.servlet.JRunRequestDispatcher.invoke(JRunRequestDispatcher.java:257)
    at
    jrun.servlet.ServletEngineService.dispatch(ServletEngineService.java:541)
    at
    jrun.servlet.http.WebService.invokeRunnable(WebService.java:172)
    at
    jrunx.scheduler.ThreadPool$DownstreamMetrics.invokeRunnable(ThreadPool.java:318)
    at
    jrunx.scheduler.ThreadPool$ThreadThrottle.invokeRunnable(ThreadPool.java:426)
    at
    jrunx.scheduler.ThreadPool$UpstreamMetrics.invokeRunnable(ThreadPool.java:264)
    at
    jrunx.scheduler.WorkerThread.run(WorkerThread.java:66)

    Hi, Thanks.
    But the problem is still there.
    If I put
    public class SimpleThread extends Thread
    No problem, but if I put
    public class SimpleThread implements Runnable
    I got java.lang.VerifyError: (class: TestNotify, method: main signature: ([Ljava/lang/String;)V) Incompatible object argument for function call
    Exception in thread "main"
    Regards,
    Youbin
    Please refer to the following code:
    public class SimpleThread implements Runnable {
        private boolean isWaited = false;
        public void run() {
            synchronized(this) {
                while (true) {
                    System.out.println("Hi ------------");
                    try {
                        Thread.sleep(5000);
                        System.out.println("Start wait()");
                        isWaited=true;
                        wait();
                        isWaited=false;
    catch (Exception e) { }
    public class TestNotify {
    public static void main(String[] args) {
    SimpleThread simpleThread = new SimpleThread();
    simpleThread.start();
    try {
    Thread.sleep(10);
    } catch (Exception e) { }
    while (simpleThread.getIsWaited()) {
    synchronized(simpleThread) {
    System.out.println("Start notify()");
    simpleThread.notify();
    System.out.println("Arrived");
    int i=0;
    while (!simpleThread.getIsWaited()) {
    i++;
    System.out.println("Arrived="+i);
    synchronized(simpleThread) {
    System.out.println("Start notify() again");
    simpleThread.notify();
    System.out.println("Arrived again");

  • Incompatible object argument for function call

    when my application is trying to access a jsp page, I am getting an error:
    Request URI:/asteroid/admin/clientDetails.jsp
    Exception:
    java.lang.VerifyError: (class: admin/clientDetails, method: _jspService signature: (Ljavax/servlet/http/HttpServletRequest;Ljavax/servlet/http/HttpServletResponse;)V) Incompatible object argument for function call
    i am using ora9ias Java edition.
    At this point I am out of ideas as of why this is happening.
    This application runs fine on oc4j stand alone.

    Is it enough to write
    set JAVA_OPT= "-noverify"
    before
    set EXECJAVA=%RUNJAVA%
    set MAINCLASS=org.apache.catalina.startup.Bootstrap
    set ACTION=start
    set SECURITY_POLICY_FILE=
    set DEBUG_OPTS=
    set JPDA=
    ?

  • How to pass in a wildcard as an argument to a method

    Hi,
    I am calling to a method which "normally" works like this:
    sContext.lookup(jndiName)
    The argument jndiName which I am passing looks like:
    /jms/topic/my/topic
    If the above jndiName exists, the method looks it up. If it does not exist, obviously an exception occurs.
    However, what I want to do is to pass a wildcard like * as an agrument for the method, so that it looks up everything that does exist. Or better yet, I want to lookup everything that starts with /jms/topic/*/*/*.
    Is this possible to do by using some wildcard? Or is there another way to do this?
    Thanks!

    I want do this because what if I don't know the jndiName (which is a string) - and I want to lookup all the ones that do exist.
    Once I get a list of all the jndiName's that exist - I will display them to the user - so the user is now aware of all the ones that exist.
    Yes, at this time the user will pass the now known jndiName as an argument and then I will look up the specifc object to use them.
    The lookup method is in the class:
    javax.naming.InitialContext
    which implements interface Context

  • HT204149 What is the maximum resolution available for use with the Apple Mini DisplayPort to Dual-Link DVI adapter?

    What is the maximum resolution available for use with the Apple Mini DisplayPort to Dual-Link DVI adapter?

    Hey guys,
    I found out an answer by myself...
    The missing link : the MacBook Pro needs to be powered... as in you need to plug the charger in...
    In conclusion, you simply plug everything, turn on the MacBook Pro, close the lid, and there you go !

  • Report fails with " Invalid argument for database." error.

    Hi All,
    Several of my reports deployed on Crystal Reports Server 2008 server fails everyday with the following error.
    Error in File ~tmp121c5dc747685036.rpt: Invalid argument for database.
    The error is not consistent, if report A fails today, it is Report B the next day. When I reschedule the reports, they run just fine. They fail only when the daily schedules run at 2:00 AM in the morning. 100 + reports are run at this time and some of the reports that fail run many times with different parameters. Is this error due to scheduling reports many times or is it something else? Appreciate any help with this.
    Thanks
    Bin

    Hi,
    can you please check under <BOBJ installation directory>\BusinessObjects Enterprise 12.0\logging in the log files created by the crystal reports job server for additionaly error messages?
    Regards,
    Stratos
    PS: Do you run CRS 2008 V0 or V1?

Maybe you are looking for