Examples of Index


Examples of org.hibernate.annotations.Index

        }
      }
    }
    //init index
    //process indexes after everything: in second pass, many to one has to be done before indexes
    Index index = property.getAnnotation( Index.class );
    if ( index != null ) {
      if ( joinColumns != null ) {

        for ( Ejb3Column column : joinColumns ) {
          column.addIndex( index, inSecondPass );
View Full Code Here

Examples of org.hibernate.mapping.Index

        }


        Iterator subIter = table.getIndexIterator();
        while ( subIter.hasNext() ) {
          Index index = (Index) subIter.next();
          script.add(
              index.sqlCreateString(
                  dialect,
                  mapping,
                  defaultCatalog,
                  defaultSchema
                )
View Full Code Here

Examples of org.hive2hive.core.model.Index

      } else if (!oldParent.canWrite(sender)) {
        logger.error("User was not allowed to change the source directory.");
        return;
      }

      Index child = oldParent.getChildByName(sourceFileName);
      if (child == null) {
        logger.error("File node that should be moved not found.");
        return;
      }

      FolderIndex newParent = (FolderIndex) userProfile.getFileById(newParentKey);
      if (newParent == null) {
        logger.error("Could not find the new parent.");
        return;
      } else if (!newParent.canWrite(sender)) {
        logger.error("User was not allowed to change the destination directory.");
        return;
      }

      // rearrange
      oldParent.removeChild(child);
      newParent.addChild(child);
      child.setParent(newParent);

      // change the child's name
      child.setName(destFileName);

      profileManager.readyToPut(userProfile, randomPID);

      // move the file on disk
      FileUtil.moveFile(session.getRoot(), sourceFileName, destFileName, oldParent, newParent);
View Full Code Here

Examples of org.hivedb.annotations.Index

    this.validator = resolveValidator(entityInterface, propertyName);
  }
 
  @SuppressWarnings("unchecked")
  private IndexType resolveIndexType(final Class entityInterface, final String propertyName) {
    Index annotation = ReflectionTools.getGetterOfProperty(entityInterface, propertyName).getAnnotation(Index.class);
    if (annotation != null)
      return annotation.type();
    if (ReflectionTools.getGetterOfProperty(entityInterface, propertyName).getAnnotation(PartitionIndex.class) != null)
      return IndexType.Partition;
    return IndexType.None;
  }
View Full Code Here

Examples of org.hsqldb.index.Index

            indexQualifier = tableCatalog;
            indexCount     = table.getIndexCount();

            // process all of the visible indices for this table
            for (int i = 0; i < indexCount; i++) {
                Index index = table.getIndex(i);

                colCount = table.getIndex(i).getColumnCount();

                if (colCount < 1) {
                    continue;
                }

                indexName      = index.getName().name;
                nonUnique      = index.isUnique() ? Boolean.FALSE
                                                  : Boolean.TRUE;
                cardinality    = null;
                pages          = ValuePool.INTEGER_0;
                rowCardinality = null;
                cols           = index.getColumns();
                indexType      = ValuePool.getInt(3);

                for (int k = 0; k < colCount; k++) {
                    col                    = cols[k];
                    row                    = t.getEmptyRowData();
View Full Code Here

Examples of org.hsqldb_voltpatches.index.Index

        bestIndexForColumn = new int[colTypes.length];

        ArrayUtil.fillArray(bestIndexForColumn, -1);

        for (int i = 0; i < indexList.length; i++) {
            Index index     = indexList[i];
            // A VoltDB extension -- Don't consider non-column expression indexes for this purpose.
            // Expression-based indexes are not suitable for row identification.
            if (index.getExpressions() != null) {
                continue;
            }
            // End of VoltDB extension
            int[] cols      = index.getColumns();
            int   colsCount = index.getVisibleColumns();

            if (colsCount == 0) {
                continue;
            }

            if (i == 0) {
                isStrict = true;
            }

            if (bestIndexForColumn[cols[0]] == -1) {
                bestIndexForColumn[cols[0]] = i;
            } else {
                Index existing = indexList[bestIndexForColumn[cols[0]]];

                if (colsCount > existing.getColumns().length) {
                    bestIndexForColumn[cols[0]] = i;
                }
            }

            if (!index.isUnique()) {
View Full Code Here

Examples of org.infinispan.configuration.cache.Index

        } else {
            // Otherwise default to cache container configuration
            builder.jmxStatistics().enabled(CacheContainerResourceDefinition.STATISTICS_ENABLED.resolveModelAttribute(context, containerModel).asBoolean());
        }

        final Index indexing = Index.valueOf(CacheResourceDefinition.INDEXING.resolveModelAttribute(context, cache).asString());

        // set the cache mode (may be modified when setting up clustering attributes)
        builder.clustering().cacheMode(this.mode);
        final ModelNode indexingPropertiesModel = CacheResourceDefinition.INDEXING_PROPERTIES.resolveModelAttribute(context, cache);
        Properties indexingProperties = new Properties();
        if (indexing.isEnabled() && indexingPropertiesModel.isDefined()) {
            for (Property p : indexingPropertiesModel.asPropertyList()) {
                String value = p.getValue().asString();
                indexingProperties.put(p.getName(), value);
            }
        }
View Full Code Here

Examples of org.jboss.dna.common.jdbc.model.api.Index

    }

    public void testAddIndex() {
        String NAME = "My Index";
        // create FK
        Index i = factory.createIndex();
        // set name
        i.setName(NAME);
        // add
        bean.addIndex(i);
        // check
        assertFalse("Index set should not be empty", bean.getIndexes().isEmpty());
    }
View Full Code Here

Examples of org.jboss.jandex.Index

        if (annotationsToLookFor.size() > 0) {  // Hibernate doesn't pass any annotations currently
            resultClasses = getClassesInJar(jartoScan, annotationsToLookFor);
        } else {
            if (pu.getAnnotationIndex() != null) {
                Index index = getJarFileIndex(jartoScan, pu);
                if (index == null) {
                    JPA_LOGGER.tracef("No classes to scan for annotations in jar '%s' (jars with classes '%s')",
                        jartoScan, pu.getAnnotationIndex().keySet());
                    return new HashSet<Package>();
                }
                Collection<ClassInfo> allClasses = index.getKnownClasses();
                for (ClassInfo classInfo : allClasses) {
                    String className = classInfo.name().toString();
                    try {
                        resultClasses.add(pu.getClassLoader().loadClass(className));
                        // TODO:  fix temp classloader (get CFNE on entity class)
View Full Code Here

Examples of org.jpox.store.rdbms.key.Index

        return "ALTER TABLE " + pk.getDatastoreContainerObject().toString() + " ADD " + pk;
    }

    public String getAddCandidateKeyStatement(CandidateKey ck, IdentifierFactory factory)
    {
        Index idx = new Index(ck);
        idx.setName(ck.getName());
        return getCreateIndexStatement(idx, factory);
    }
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.