Example usage for org.apache.commons.collections.primitives IntIterator hashCode

List of usage examples for org.apache.commons.collections.primitives IntIterator hashCode

Introduction

In this page you can find the example usage for org.apache.commons.collections.primitives IntIterator hashCode.

Prototype

@HotSpotIntrinsicCandidate
public native int hashCode();

Source Link

Document

Returns a hash code value for the object.

Usage

From source file:dbs_project.storage.impl.Tables.java

@Override
public void dropColumns(IntIterator columnIds) throws NoSuchColumnException {
    Object[] values = tablaEsquema.values().toArray();
    do {/*from  w  ww . j  a va 2  s .co m*/
        tablaEsquema.remove(columnIds.hashCode());
        columnIds.next();
    } while (columnIds.hasNext());
    throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
}

From source file:dbs_project.storage.impl.Tables.java

@Override
public void deleteRows(IntIterator rowIDs) throws NoSuchRowException {

    NoSuchRow(rowIDs);/*from  www  .  j  av  a  2  s. co  m*/
    for (int i = 0; tablaEsquema.size() > i; ++i) {

        tablaEsquema.get(i).removeRow(rowIDs.hashCode());
    }
    MetaData.dicreaseCount();
}

From source file:dbs_project.storage.impl.Tables.java

@Override
public void updateRows(IntIterator rowIDs, RowCursor newRows)
        throws SchemaMismatchException, NoSuchRowException {
    RowCursors row1 = (RowCursors) newRows;
    SchemaMismatchRow(row1.getMetaData().getColumnCount());
    Object[] values = tablaEsquema.values().toArray();
    int indice = 0;
    do {/*from   w  w w  .j  a v a 2 s .com*/
        for (Object i : values) {
            Columns columna = (Columns) i;
            try {
                DoublyLinkedList lista = (DoublyLinkedList) columna.getList();
                lista.goToPos(rowIDs.hashCode());
                lista.setElement(row1.getMetaData().getColumnMetaData(indice));
            } catch (ClassCastException e) {
                LinkedList lista = (LinkedList) columna.getList();
                lista.goToPos(rowIDs.hashCode());
                lista.setElement(row1.getElement().getMetaData());
            }
            indice++;
        }
        rowIDs.next();
        row1.next();
    } while (rowIDs.hasNext());
}

From source file:dbs_project.storage.impl.Tables.java

@Override
public void updateColumns(IntIterator columnIDs, ColumnCursor updateColumns)
        throws SchemaMismatchException, NoSuchColumnException {
    NoSuchColumn(columnIDs);/*from   w  w  w.jav a2  s  . c o m*/
    Object[] values = tablaEsquema.values().toArray();
    Columns columna = (Columns) values[0];
    ColumnCursors columna2 = (ColumnCursors) updateColumns;
    do {
        if (columna.getMetaData().getRowCount() != updateColumns.getMetaData().getRowCount()) {
            throw new SchemaMismatchException("La columna no coincide con el numero de filas");
        }
        tablaEsquema.put(columnIDs.hashCode(), columna2.getElement());
        columna2.next();
        columnIDs.next();
    } while (columnIDs.hasNext());
}