Package org.hsqldb.lib

Examples of org.hsqldb.lib.LongDeque


        read();

        OrderedHashSet targetSet    = new OrderedHashSet();
        HsqlArrayList  exprList     = new HsqlArrayList();
        LongDeque      colIndexList = new LongDeque();

        readSetClauseList(rangeVars, targetSet, colIndexList, exprList);

        if (exprList.size() > 1) {
            throw Error.error(ErrorCode.X_42602);
        }

        Expression expression = (Expression) exprList.get(0);

        if (expression.getDegree() != targetSet.size()) {
            throw Error.error(ErrorCode.X_42546, Tokens.T_SET);
        }

        int[] columnMap = new int[colIndexList.size()];

        colIndexList.toArray(columnMap);

        Expression[] targets = new Expression[targetSet.size()];

        targetSet.toArray(targets);
View Full Code Here


        int[]          columnMap;
        OrderedHashSet targetSet = new OrderedHashSet();
        HsqlArrayList  exprList  = new HsqlArrayList();
        RangeVariable[] targetRangeVars = new RangeVariable[]{
            rangeVars[TriggerDef.NEW_ROW] };
        LongDeque colIndexList = new LongDeque();

        readSetClauseList(targetRangeVars, targetSet, colIndexList, exprList);

        columnMap = new int[colIndexList.size()];

        colIndexList.toArray(columnMap);

        Expression[] targets = new Expression[targetSet.size()];

        targetSet.toArray(targets);
View Full Code Here

        Expression[]   updateExpressions;
        int[]          columnMap;
        boolean[]      columnCheckList;
        OrderedHashSet targetSet    = new OrderedHashSet();
        LongDeque      colIndexList = new LongDeque();
        HsqlArrayList  exprList     = new HsqlArrayList();
        RangeVariable[] rangeVariables = {
            readSimpleRangeVariable(StatementTypes.UPDATE_WHERE) };
        Table table     = rangeVariables[0].rangeTable;
        Table baseTable = table.isTriggerUpdatable() ? table
                                                     : table.getBaseTable();

        if (table.isTriggerDeletable()) {
            rangeVariables[0].resetViewRageTableAsSubquery();
        }

        readThis(Tokens.SET);
        readSetClauseList(rangeVariables, targetSet, colIndexList, exprList);

        columnMap = new int[colIndexList.size()];

        colIndexList.toArray(columnMap);

        Expression[] targets = new Expression[targetSet.size()];

        targetSet.toArray(targets);
View Full Code Here

        insertColumnMap       = table.getColumnMap();
        insertColumnCheckList = table.getNewColumnCheckList();

        OrderedHashSet updateTargetSet    = new OrderedHashSet();
        OrderedHashSet insertColNames     = new OrderedHashSet();
        LongDeque      updateColIndexList = new LongDeque();

        readMergeWhen(updateColIndexList, insertColNames, updateTargetSet,
                      insertList, updateList, targetRangeVars, sourceRange);

        if (insertList.size() > 0) {
            int colCount = insertColNames.size();

            if (colCount != 0) {
                insertColumnMap = table.getColumnIndexes(insertColNames);
                insertColumnCheckList =
                    table.getColumnCheckList(insertColumnMap);
            }

            insertExpression = (Expression) insertList.get(0);

            setParameterTypes(insertExpression, table, insertColumnMap);
        }

        if (updateList.size() > 0) {
            targets = new Expression[updateTargetSet.size()];

            updateTargetSet.toArray(targets);

            for (int i = 0; i < targets.length; i++) {
                this.resolveOuterReferencesAndTypes(outerRanges, targets[i]);
            }

            updateExpressions = new Expression[updateList.size()];

            updateList.toArray(updateExpressions);

            updateColumnMap = new int[updateColIndexList.size()];

            updateColIndexList.toArray(updateColumnMap);
        }

        if (updateExpressions.length != 0) {
            Table baseTable = table.isTriggerUpdatable() ? table
                                                         : table.getBaseTable();
View Full Code Here

    SessionContext(Session session) {

        this.session             = session;
        rangeIterators           = new RangeIterator[4];
        savepoints               = new HashMappedList(4);
        savepointTimestamps      = new LongDeque();
        sessionVariables         = new HashMappedList();
        sessionVariablesRange    = new RangeVariable[1];
        sessionVariablesRange[0] = new RangeVariable(sessionVariables, true);
    }
View Full Code Here

        stack.add(savepoints);
        stack.add(savepointTimestamps);

        rangeIterators      = new RangeIterator[4];
        savepoints          = new HashMappedList(4);
        savepointTimestamps = new LongDeque();

        String name =
            HsqlNameManager.getAutoSavepointNameString(session.actionTimestamp,
                depth);
View Full Code Here

TOP

Related Classes of org.hsqldb.lib.LongDeque

Copyright © 2018 www.massapicom. 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.