Package org.apache.derby.iapi.store.access.conglomerate

Examples of org.apache.derby.iapi.store.access.conglomerate.Conglomerate


    public Conglomerate readConglomerate(
    TransactionManager  xact_manager,
    ContainerKey        container_key)
    throws StandardException
    {
        Conglomerate    btree      = null;
        ContainerHandle container  = null;
        ControlRow      root       = null;

        try
        {
View Full Code Here


    }

  private Conglomerate findExistingConglomerate(long conglomId)
    throws StandardException
  {
    Conglomerate conglom = null;

    if (conglomId < 0)
    {
      if (tempCongloms != null)
        conglom = (Conglomerate) tempCongloms.get(new Long(conglomId));
View Full Code Here

  }

  private Conglomerate findConglomerate(long conglomId)
    throws StandardException
  {
    Conglomerate conglom = null;

    if (conglomId >= 0)
        {
            conglom = accessmanager.conglomCacheFind(this, conglomId);
        }
View Full Code Here

    int         collation_id)
    throws StandardException
    {
        boolean is_temporary = (conglomId < 0);

    Conglomerate conglom = findConglomerate(conglomId);
    if (conglom == null)
        {
      throw StandardException.newException(
                SQLState.AM_NO_SUCH_CONGLOMERATE_DROP, new Long(conglomId));
        }

        // Get exclusive lock on the table being altered.
    ConglomerateController cc =
            conglom.open(
                this, rawtran, false, OPENMODE_FORUPDATE,
                MODE_TABLE,
                accessmanager.table_level_policy[
                    TransactionController.ISOLATION_SERIALIZABLE],
                (StaticCompiledOpenConglomInfo) null,
                (DynamicCompiledOpenConglomInfo) null);

    conglom.addColumn(this, column_id, template_column, collation_id);

        // remove the old entry in the Conglomerate directory, and add the
        // new one.
    if (is_temporary)
    {
View Full Code Here

                accessmanager.getNextConglomId(
                    cfactory.getConglomerateFactoryId());
        }

        // call the factory to actually create the conglomerate.
        Conglomerate conglom =
            cfactory.createConglomerate(
                this, segment, conglomid, template,
                columnOrder, collationIds, properties, temporaryFlag);

    long conglomId;
    if ((temporaryFlag & TransactionController.IS_TEMPORARY)
        == TransactionController.IS_TEMPORARY)
    {
      conglomId = nextTempConglomId--;
      if (tempCongloms == null)
        tempCongloms = new HashMap();
      tempCongloms.put(new Long(conglomId), conglom);
    }
    else
    {
      conglomId = conglom.getContainerid();

            accessmanager.conglomCacheAddEntry(conglomId, conglom);
    }

    return conglomId;
View Full Code Here

      {
                for (Iterator it = tempCongloms.keySet().iterator();
                     it.hasNext(); )
                {
          Long conglomId = (Long) it.next();
          Conglomerate c = (Conglomerate) tempCongloms.get(conglomId);
          str += "temp conglomerate id = " + conglomId + ": " + c;
        }
      }

        }
View Full Code Here

    }

    public boolean conglomerateExists(long conglomId)
    throws StandardException
  {
    Conglomerate conglom = findConglomerate(conglomId);
    if (conglom == null)
      return false;
    return true;
  }
View Full Code Here

  }

    public void dropConglomerate(long conglomId)
    throws StandardException
  {
    Conglomerate conglom = findExistingConglomerate(conglomId);

    conglom.drop(this);

    if (conglomId < 0)
    {
      if (tempCongloms != null)
        tempCongloms.remove(new Long(conglomId));
View Full Code Here

    FormatableBitSet                 scanColumnList,
    DataValueDescriptor[]   fetchRow)
        throws StandardException
    {
    // Find the conglomerate.
    Conglomerate conglom = findExistingConglomerate(conglomId);

    // Get a scan controller.
        return(
            conglom.fetchMaxOnBTree(
                this,
                rawtran,
                conglomId,
                open_mode,
                lock_level,
View Full Code Here

    boolean                 createConglom,
    RowLocationRetRowSource rowSource)
    throws StandardException
  {
    // Find the conglomerate.
    Conglomerate conglom = findExistingConglomerate(conglomId);

    // Load up the conglomerate with rows from the rowSource.
    // Don't need to keep track of the conglomerate controller because load
    // automatically closes it when it finished.
    return(conglom.load(this, createConglom, rowSource));
  }
View Full Code Here

TOP

Related Classes of org.apache.derby.iapi.store.access.conglomerate.Conglomerate

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.