Examples of addIndex()


Examples of org.h2.table.RegularTable.addIndex()

                    tableColumns[indexColumn.column.getColumnId()].setNullable(false);
                }
            } else {
                indexType = IndexType.createNonUnique(true);
            }
            meta = table.addIndex(session, "I" + id, id, cols, indexType, false, null);
        }
        PageIndex index;
        if (meta instanceof MultiVersionIndex) {
            index = (PageIndex) ((MultiVersionIndex) meta).getBaseIndex();
        } else {
View Full Code Here

Examples of org.h2.table.Table.addIndex()

            indexType = IndexType.createUnique(persistent, hash);
        } else {
            indexType = IndexType.createNonUnique(persistent, hash);
        }
        IndexColumn.mapColumns(indexColumns, table);
        table.addIndex(session, indexName, id, indexColumns, indexType, create, comment);
        return 0;
    }

    public void setPrimaryKey(boolean b) {
        this.primaryKey = b;
View Full Code Here

Examples of org.h2.table.Table.addIndex()

            if (index == null) {
                IndexType indexType = IndexType.createPrimaryKey(table.isPersistIndexes(), primaryKeyHash);
                String indexName = table.getSchema().getUniqueIndexName(session, table, Constants.PREFIX_PRIMARY_KEY);
                int id = getObjectId();
                try {
                    index = table.addIndex(session, indexName, id, indexColumns, indexType, true, null);
                } finally {
                    getSchema().freeUniqueName(indexName);
                }
            }
            index.getIndexType().setBelongsToConstraint(true);
View Full Code Here

Examples of org.jpox.metadata.AbstractClassMetaData.addIndex()

                    Iterator iter = indices.iterator();
                    while (iter.hasNext())
                    {
                        IndexMetaData idxmd = (IndexMetaData)iter.next();
                        idxmd.setParent(cmd);
                        cmd.addIndex(idxmd);
                    }
                }
                if (uniqueKeys != null)
                {
                    Iterator iter = uniqueKeys.iterator();
View Full Code Here

Examples of org.jpox.metadata.AbstractClassMetaData.addIndex()

                                getAttr(attrs,"table"),
                                getAttr(attrs,"unique"));
                if (md instanceof AbstractClassMetaData)
                {
                    AbstractClassMetaData cmd = (AbstractClassMetaData)md;
                    cmd.addIndex(idxmd);
                }
                else if (md instanceof AbstractMemberMetaData)
                {
                    AbstractMemberMetaData fmd = (AbstractMemberMetaData)md;
                    fmd.setIndexMetaData(idxmd);
View Full Code Here

Examples of org.jpox.metadata.ClassMetaData.addIndex()

                                getAttr(attrs,"table"),
                                getAttr(attrs,"unique"));
                if (md instanceof AbstractClassMetaData)
                {
                    AbstractClassMetaData cmd = (AbstractClassMetaData)md;
                    cmd.addIndex(idxmd);
                }
                else if (md instanceof AbstractMemberMetaData)
                {
                    AbstractMemberMetaData fmd = (AbstractMemberMetaData)md;
                    fmd.setIndexMetaData(idxmd);
View Full Code Here

Examples of org.jvnet.hk2.component.Habitat.addIndex()

                parseInhabitants(module, name,parser);

            populateConfig(habitat);

            // default modules registry is the one that created the habitat
            habitat.addIndex(new ExistingSingletonInhabitant<ModulesRegistry>(this),
                    ModulesRegistry.class.getName(), null);
            habitats.put(name, habitat);

            habitat.initialized();
           
View Full Code Here

Examples of org.lealone.dbobject.table.Table.addIndex()

            indexType = IndexType.createUnique(persistent, hash);
        } else {
            indexType = IndexType.createNonUnique(persistent, hash);
        }
        IndexColumn.mapColumns(indexColumns, table);
        table.addIndex(session, indexName, id, indexColumns, indexType, create, comment);
        return 0;
    }

    public void setPrimaryKey(boolean b) {
        this.primaryKey = b;
View Full Code Here

Examples of org.lealone.expression.Calculator.addIndex()

                Expression expr = expressions.get(i);
                index = calculator.getIndex();
                expr.calculate(calculator);
                if (calculator.getIndex() == index) {
                    calculator.addResultValue(calculator.getValue(index));
                    calculator.addIndex();
                }
            }

            lr.addRow(calculator.getResult().toArray(new Value[0]));
        }
View Full Code Here

Examples of org.molgenis.model.elements.Entity.addIndex()

          }
        }

        try
        {
          entity.addIndex(index);
        }
        catch (Exception e)
        {
        }
      }
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.