当前位置: 首页>>代码示例>>Java>>正文


Java ArrayUtil.projectRow方法代码示例

本文整理汇总了Java中org.hsqldb.lib.ArrayUtil.projectRow方法的典型用法代码示例。如果您正苦于以下问题:Java ArrayUtil.projectRow方法的具体用法?Java ArrayUtil.projectRow怎么用?Java ArrayUtil.projectRow使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.hsqldb.lib.ArrayUtil的用法示例。


在下文中一共展示了ArrayUtil.projectRow方法的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: resolveTypesPartOne

import org.hsqldb.lib.ArrayUtil; //导入方法依赖的package包/类
void resolveTypesPartOne(Session session) {

        if (isPartOneResolved) {
            return;
        }

        ArrayUtil.projectRowReverse(leftQueryExpression.unionColumnTypes,
                                    leftQueryExpression.unionColumnMap,
                                    unionColumnTypes);
        leftQueryExpression.resolveTypesPartOne(session);
        ArrayUtil.projectRow(leftQueryExpression.unionColumnTypes,
                             leftQueryExpression.unionColumnMap,
                             unionColumnTypes);
        ArrayUtil.projectRowReverse(rightQueryExpression.unionColumnTypes,
                                    rightQueryExpression.unionColumnMap,
                                    unionColumnTypes);
        rightQueryExpression.resolveTypesPartOne(session);
        ArrayUtil.projectRow(rightQueryExpression.unionColumnTypes,
                             rightQueryExpression.unionColumnMap,
                             unionColumnTypes);

        isPartOneResolved = true;
    }
 
开发者ID:tiweGH,项目名称:OpenDiabetes,代码行数:24,代码来源:QueryExpression.java

示例2: addAdjusted

import org.hsqldb.lib.ArrayUtil; //导入方法依赖的package包/类
void addAdjusted(Object[] data, int[] columnMap) {

        try {
            if (columnMap == null) {
                data = (Object[]) ArrayUtil.resizeArrayIfDifferent(data,
                        visibleColumnCount);
            } else {
                Object[] newData = new Object[visibleColumnCount];

                ArrayUtil.projectRow(data, columnMap, newData);

                data = newData;
            }

            add(data);
        } catch (HsqlException e) {}
    }
 
开发者ID:tiweGH,项目名称:OpenDiabetes,代码行数:18,代码来源:RowSetNavigatorDataTable.java

示例3: resolveTypesPartOne

import org.hsqldb.lib.ArrayUtil; //导入方法依赖的package包/类
void resolveTypesPartOne(Session session) {

        ArrayUtil.projectRowReverse(leftQueryExpression.unionColumnTypes,
                                    leftQueryExpression.unionColumnMap,
                                    unionColumnTypes);
        leftQueryExpression.resolveTypesPartOne(session);
        ArrayUtil.projectRow(leftQueryExpression.unionColumnTypes,
                             leftQueryExpression.unionColumnMap,
                             unionColumnTypes);
        ArrayUtil.projectRowReverse(rightQueryExpression.unionColumnTypes,
                                    rightQueryExpression.unionColumnMap,
                                    unionColumnTypes);
        rightQueryExpression.resolveTypesPartOne(session);
        ArrayUtil.projectRow(rightQueryExpression.unionColumnTypes,
                             rightQueryExpression.unionColumnMap,
                             unionColumnTypes);
    }
 
开发者ID:s-store,项目名称:sstore-soft,代码行数:18,代码来源:QueryExpression.java

示例4: addAdjusted

import org.hsqldb.lib.ArrayUtil; //导入方法依赖的package包/类
private void addAdjusted(Object[] data, int[] columnMap) {

        try {
            if (columnMap == null) {
                data = (Object[]) ArrayUtil.resizeArrayIfDifferent(data,
                        table.getColumnCount());
            } else {
                Object[] newData = new Object[table.getColumnCount()];

                ArrayUtil.projectRow(data, columnMap, newData);

                data = newData;
            }

            Row row = (Row) store.getNewCachedObject(session, data);

            store.indexRow(null, row);

            size++;
        } catch (HsqlException e) {}
    }
 
开发者ID:s-store,项目名称:sstore-soft,代码行数:22,代码来源:RowSetNavigatorData.java

示例5: createPrimaryKey

import org.hsqldb.lib.ArrayUtil; //导入方法依赖的package包/类
/**
 *  Creates a single or multi-column primary key and index. sets the
 *  colTypes array. Finalises the creation of the table. ([email protected])
 */
public void createPrimaryKey(HsqlName indexName, int[] columns,
                             boolean columnsNotNull) {

    if (columns == null) {
        columns = ValuePool.emptyIntArray;
    }

    for (int i = 0; i < columns.length; i++) {
        getColumn(columns[i]).setPrimaryKey(true);
    }

    setColumnStructures();

    Type[] primaryKeyTypes = new Type[columns.length];

    ArrayUtil.projectRow(colTypes, columns, primaryKeyTypes);

    HsqlName name = indexName;

    if (name == null) {
        name = database.nameManager.newAutoName("IDX", getSchemaName(),
                getName(), SchemaObject.INDEX);
    }

    createPrimaryIndex(columns, primaryKeyTypes, name);
    setBestRowIdentifiers();
}
 
开发者ID:tiweGH,项目名称:OpenDiabetes,代码行数:32,代码来源:Table.java

示例6: projectData

import org.hsqldb.lib.ArrayUtil; //导入方法依赖的package包/类
Object[] projectData(Object[] data, int[] columnMap) {

        if (columnMap == null) {
            data = (Object[]) ArrayUtil.resizeArrayIfDifferent(data,
                    visibleColumnCount);
        } else {
            Object[] newData = new Object[visibleColumnCount];

            ArrayUtil.projectRow(data, columnMap, newData);

            data = newData;
        }

        return data;
    }
 
开发者ID:tiweGH,项目名称:OpenDiabetes,代码行数:16,代码来源:RowSetNavigatorData.java

示例7: createPrimaryKey

import org.hsqldb.lib.ArrayUtil; //导入方法依赖的package包/类
/**
 * Creates a single or multi-column primary key and index. sets the colTypes
 * array. Finalises the creation of the table. ([email protected])
 */
public void createPrimaryKey(HsqlName indexName, int[] columns, boolean columnsNotNull) {

    if (primaryKeyCols != null) {
        throw Error.runtimeError(ErrorCode.U_S0500, "Table");
    }

    if (columns == null) {
        columns = ValuePool.emptyIntArray;
    } else {
        for (int i = 0; i < columns.length; i++) {
            getColumn(columns[i]).setPrimaryKey(true);
        }
    }

    primaryKeyCols = columns;

    setColumnStructures();

    primaryKeyTypes = new Type[primaryKeyCols.length];

    ArrayUtil.projectRow(colTypes, primaryKeyCols, primaryKeyTypes);

    primaryKeyColsSequence = new int[primaryKeyCols.length];

    ArrayUtil.fillSequence(primaryKeyColsSequence);

    HsqlName name = indexName;

    if (name == null) {
        name = database.nameManager.newAutoName("IDX", getSchemaName(), getName(), SchemaObject.INDEX);
    }

    createPrimaryIndex(primaryKeyCols, primaryKeyTypes, name);
    setBestRowIdentifiers();
}
 
开发者ID:s-store,项目名称:sstore-soft,代码行数:40,代码来源:Table.java

示例8: newIndex

import org.hsqldb.lib.ArrayUtil; //导入方法依赖的package包/类
public Index newIndex(Table table, Index index, int[] columns) {

        boolean[] modeFlags = new boolean[columns.length];
        Type[]    colTypes  = new Type[columns.length];

        ArrayUtil.projectRow(table.getColumnTypes(), columns, colTypes);

        return newIndex(index.getName(), index.getPersistenceId(), table,
                        columns, modeFlags, modeFlags, colTypes, false, false,
                        false, false);
    }
 
开发者ID:Julien35,项目名称:dev-courses,代码行数:12,代码来源:Logger.java

示例9: createPrimaryKey

import org.hsqldb.lib.ArrayUtil; //导入方法依赖的package包/类
/**
 *  Creates a single or multi-column primary key and index. sets the
 *  colTypes array. Finalises the creation of the table. ([email protected])
 */
public void createPrimaryKey(HsqlName indexName, int[] columns,
                             boolean columnsNotNull) {

    if (primaryKeyCols != null) {
        throw Error.runtimeError(ErrorCode.U_S0500, "Table");
    }

    if (columns == null) {
        columns = ValuePool.emptyIntArray;
    }

    for (int i = 0; i < columns.length; i++) {
        getColumn(columns[i]).setPrimaryKey(true);
    }

    primaryKeyCols = columns;

    setColumnStructures();

    primaryKeyTypes = new Type[primaryKeyCols.length];

    ArrayUtil.projectRow(colTypes, primaryKeyCols, primaryKeyTypes);

    primaryKeyColsSequence = new int[primaryKeyCols.length];

    ArrayUtil.fillSequence(primaryKeyColsSequence);

    HsqlName name = indexName;

    if (name == null) {
        name = database.nameManager.newAutoName("IDX", getSchemaName(),
                getName(), SchemaObject.INDEX);
    }

    createPrimaryIndex(primaryKeyCols, primaryKeyTypes, name);
    setBestRowIdentifiers();
}
 
开发者ID:Julien35,项目名称:dev-courses,代码行数:42,代码来源:Table.java

示例10: alterIndex

import org.hsqldb.lib.ArrayUtil; //导入方法依赖的package包/类
void alterIndex(Index index, int[] columns) {

        PersistentStore store =
            database.persistentStoreCollection.getStore(table);
        int       position  = index.getPosition();
        boolean[] modeFlags = new boolean[columns.length];
        Type[]    colTypes  = new Type[columns.length];

        ArrayUtil.projectRow(table.getColumnTypes(), columns, colTypes);

        Index newIndex = database.logger.newIndex(index.getName(),
            index.getPersistenceId(), table, columns, modeFlags, modeFlags,
            colTypes, false, false, false, false);

        newIndex.setPosition(position);

        table.getIndexList()[position] = newIndex;

        table.setBestRowIdentifiers();

        Index[] indexes = store.getAccessorKeys();

        indexes[position] = newIndex;

        store.reindex(session, newIndex);
    }
 
开发者ID:tiweGH,项目名称:OpenDiabetes,代码行数:27,代码来源:TableWorks.java

示例11: getNewMetaData

import org.hsqldb.lib.ArrayUtil; //导入方法依赖的package包/类
public ResultMetaData getNewMetaData(int[] columnMap) {

        ResultMetaData newMeta = newResultMetaData(columnMap.length);

        ArrayUtil.projectRow(columnLabels, columnMap, newMeta.columnLabels);
        ArrayUtil.projectRow(columnTypes, columnMap, newMeta.columnTypes);
        ArrayUtil.projectRow(columns, columnMap, newMeta.columns);

        return newMeta;
    }
 
开发者ID:tiweGH,项目名称:OpenDiabetes,代码行数:11,代码来源:ResultMetaData.java


注:本文中的org.hsqldb.lib.ArrayUtil.projectRow方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。