Examples of ParameterNode


Examples of javax.validation.Path.ParameterNode

    );

    assertTrue( nodeIter.hasNext() );
    nextNode = nodeIter.next();
    assertNode( nextNode, "arg0", ElementKind.PARAMETER, false, null, null );
    ParameterNode parameterNode = nextNode.as( ParameterNode.class );
    assertNotNull( parameterNode );
    assertEquals( parameterNode.getParameterIndex(), 0 );

    assertFalse( nodeIter.hasNext() );

    //parameter 1
    nodeIter = getConstraintViolationForParameter( constraintViolations, "arg1" ).getPropertyPath().iterator();

    assertTrue( nodeIter.hasNext() );
    assertNode( nodeIter.next(), methodName, ElementKind.METHOD, false, null, null );

    assertTrue( nodeIter.hasNext() );
    nextNode = nodeIter.next();
    assertNode( nextNode, "arg1", ElementKind.PARAMETER, false, null, null );
    parameterNode = nextNode.as( ParameterNode.class );
    assertNotNull( parameterNode );
    assertEquals( parameterNode.getParameterIndex(), 1 );

    assertFalse( nodeIter.hasNext() );
  }
View Full Code Here

Examples of macromedia.asc.parser.ParameterNode

                    int size = pln.items.size();
                    paramNames = new String[size];
                    paramTypes = new String[size];
                    paramDefaults = new String[size];
                    //param_names
                    ParameterNode pn;
                    for (int i = 0; i < size; i++)
                    {
                        pn = pln.items.get(i);
                        //parameter names
                        paramNames[i] = pn.ref != null ? pn.ref.name : "";
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.ParameterNode

                cc.setParameterList(parameterList);
                /* Link the untyped parameters to the array of parameter descriptors */

                DataTypeDescriptor[] descriptors = cc.getParameterTypes();

                ParameterNode                           newNode;
                ParameterNode                           oldNode;
                int                                                     paramCount;

                /*
    ** Iterate through the list of untyped parameter nodes, set each one
    ** to point to the array of parameter descriptors.
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.ParameterNode

   @exception  StandardException
   */
        ParameterNode   makeParameterNode(  )
                                        throws StandardException
        {
                ParameterNode   parm;
                DataValueDescriptor sdv = null;

                if ((paramDefaults != null) && (parameterNumber < paramDefaults.length))
                {
                        sdv = (DataValueDescriptor) paramDefaults[parameterNumber];
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.ParameterNode

   @return  corresponding unnamed parameter.
   *
   */
        ParameterNode   lookupUnnamedParameter( int paramNumber )
        {
                ParameterNode           unnamedParameter;

                unnamedParameter = (ParameterNode) parameterList.elementAt( paramNumber );
                return unnamedParameter;
        }
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.ParameterNode

/*
* <A NAME="bareCallStatement">baseCallStatement</A>
*/
  final public StatementNode bareCallStatement() throws ParseException, StandardException {
        ParameterNode           returnParam;

        ValueNode                       value;

        ResultSetNode           resultSetNode;
    switch (jj_nt.kind) {
    case CALL:
      jj_consume_token(CALL);
      value = primaryExpression(true);
                if (! (value instanceof JavaToSQLValueNode) ||
                        ! (((JavaToSQLValueNode) value).getJavaValueNode() instanceof MethodCallNode))
                {
                        {if (true) throw StandardException.newException(SQLState.LANG_INVALID_CALL_STATEMENT);}
                }

                StatementNode callStatement =
                                                                        (StatementNode) nodeFactory.getNode(
                                                                                                C_NodeTypes.CALL_STATEMENT_NODE,
                                                                                                value,
                                                                                                getContextManager());

                setUpAndLinkParameters();

                {if (true) return callStatement;}
      break;
    case QUESTION_MARK:
      returnParam = dynamicParameterSpecification();
                getCompilerContext().setReturnParameterFlag(); //bug4450

      jj_consume_token(EQUALS_OPERATOR);
      jj_consume_token(CALL);
      resultSetNode = rowValueConstructor(null);
                // validate that we have something that is an appropriate call statement
                ResultColumnList rcl = resultSetNode.getResultColumns();

                // we can have only 1 return value/column
                if (rcl == null || rcl.size() > 1)
                {
                        {if (true) throw StandardException.newException(SQLState.LANG_INVALID_CALL_STATEMENT);}
                }

                // we must have a method call node
                value = ((ResultColumn) rcl.elementAt(0)).getExpression();
                if (! (value instanceof JavaToSQLValueNode) ||
                        ! (((JavaToSQLValueNode) value).getJavaValueNode() instanceof MethodCallNode))
                {
                        {if (true) throw StandardException.newException(SQLState.LANG_INVALID_CALL_STATEMENT);}
                }

                // wrap the row result set in a cursor node
                StatementNode cursorNode =
                                        (StatementNode) nodeFactory.getNode(
                                                C_NodeTypes.CURSOR_NODE,
                                                "SELECT",
                                                resultSetNode,
                                                null,
                                                null,
                                                ReuseFactory.getInteger(CursorNode.READ_ONLY),
                                                null,
                                                getContextManager());

                // set the 0th param to be a RETURN param
                returnParam.setReturnOutputParam(value);

                setUpAndLinkParameters();

                {if (true) return cursorNode;}
      break;
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.ParameterNode

* <A NAME="nonStaticMethodInvocation">nonStaticMethodInvocation</A>
*/
  final public ValueNode nonStaticMethodInvocation(ValueNode receiver) throws ParseException, StandardException {
        Vector                                  parameterList = new Vector();
        MethodCallNode                  methodNode;
        ParameterNode                   parameterNode;
    if (getToken(3).kind == LEFT_PAREN) {
      switch (jj_nt.kind) {
      case FIELD_REFERENCE:
        jj_consume_token(FIELD_REFERENCE);
        break;
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.ParameterNode

    setSchema = setSchemaValues();
                if (parameterList != null && parameterList.size() > 0)
                {
                        setUpAndLinkParameters();
                        // set the type of parameter node, it should be a varchar max Limits.MAX_IDENTIFIER_LENGTH - non nullable
                        ParameterNode p = (ParameterNode)parameterList.elementAt(0);
                        p.setType(new DataTypeDescriptor(TypeId.getBuiltInTypeId(Types.VARCHAR), false, Limits.MAX_IDENTIFIER_LENGTH));
                }
                {if (true) return setSchema;}
    throw new Error("Missing return statement in function");
  }
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.ParameterNode

                cc.setParameterList(parameterList);
                /* Link the untyped parameters to the array of parameter descriptors */

                DataTypeDescriptor[] descriptors = cc.getParameterTypes();

                ParameterNode                           newNode;
                ParameterNode                           oldNode;
                int                                                     paramCount;

                /*
    ** Iterate through the list of untyped parameter nodes, set each one
    ** to point to the array of parameter descriptors.
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.ParameterNode

   @exception  StandardException
   */
        ParameterNode   makeParameterNode(  )
                                        throws StandardException
        {
                ParameterNode   parm;
                DataValueDescriptor sdv = null;

                if ((paramDefaults != null) && (parameterNumber < paramDefaults.length))
                {
                        sdv = (DataValueDescriptor) paramDefaults[parameterNumber];
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.