Package net.sf.joafip.kvstore.record.entity

Examples of net.sf.joafip.kvstore.record.entity.DataRecordIdentifier


    dataManager.writeDataRecord(StoreForTest.IDENTIFIER_FOR_STORE_HEADER,
        new byte[] {});
    writeDataRecord(StoreForTest.IDENTIFIER_FOR_ROOT,
        new DataRecordIdentifier[] {});
    // before 1000 create in the test, after used by manager
    dataManager.setNextFreeDataRecordIdentifier(new DataRecordIdentifier(
        1000));
    dataManager.flush();

    final HeapRecordableManager heapRecordableManager = new HeapRecordableManager(
        dataManager);
View Full Code Here


      throws HeapException {
    return dataManager.hasDataRecord(dataRecordIdentifier);
  }

  private boolean hasDataRecord(final long identifier) throws HeapException {
    return hasDataRecord(new DataRecordIdentifier(identifier));
  }
View Full Code Here

  private boolean hasDataRecord(final long identifier) throws HeapException {
    return hasDataRecord(new DataRecordIdentifier(identifier));
  }

  private void addCandidate(final long identifier) throws GarbageException {
    garbageManager.addCandidate(new DataRecordIdentifier(identifier));
  }
View Full Code Here

  private void addCandidate(final long identifier) throws GarbageException {
    garbageManager.addCandidate(new DataRecordIdentifier(identifier));
  }

  private void attachToRoot(final long identifier) {
    attachedToRoot.add(new DataRecordIdentifier(identifier));
  }
View Full Code Here

  }

  private void addLink(final long referencing, final long referenced)
      throws HeapException, ObjectIODataRecordNotFoundException,
      IOException, ClassNotFoundException {
    final DataRecordIdentifier referencingDataRecordIdentifier = new DataRecordIdentifier(
        referencing);
    final DataRecordIdentifier referencedDataRecordIdentifier = new DataRecordIdentifier(
        referenced);
    linkManager.addLink(referencingDataRecordIdentifier,
        referencedDataRecordIdentifier);

    final Set<DataRecordIdentifier> set = new TreeSet<DataRecordIdentifier>();
View Full Code Here

  }

  private void removeLink(final long referencing, final long referenced)
      throws HeapException, ObjectIODataRecordNotFoundException,
      IOException, ClassNotFoundException {
    final DataRecordIdentifier referencingDataRecordIdentifier = new DataRecordIdentifier(
        referencing);
    final DataRecordIdentifier referencedDataRecordIdentifier = new DataRecordIdentifier(
        referenced);
    linkManager.removeLink(referencingDataRecordIdentifier,
        referencedDataRecordIdentifier);

    DataRecordIdentifier[] referencedList = readDataRecord(referencingDataRecordIdentifier);
View Full Code Here

  }

  @SuppressWarnings("unused")
  private boolean isReferenced(final long identifier)
      throws GarbageException, ReferenceLinkGarbageException {
    final DataRecordIdentifier dataRecordIdentifier = new DataRecordIdentifier(
        identifier);
    return linkManager.isReferenced(dataRecordIdentifier);
  }
View Full Code Here

    for (DataRecordIdentifierRBTNode node : nodeList) {
      list.add(node.getElement());
    }
    for (long identifier : identifiers) {
      assertTrue(identifier + " must be candidate",
          list.contains(new DataRecordIdentifier(identifier)));// NOPMD
    }
  }
View Full Code Here

    for (DataRecordIdentifierRBTNode node : nodeList) {
      list.add(node.getElement());
    }
    for (long identifier : identifiers) {
      assertTrue(identifier + " must be to garbage",
          list.contains(new DataRecordIdentifier(identifier)));// NOPMD
    }
  }
View Full Code Here

    // ObjectAndPersistInfo(
    // bob1, false, bob1ClassInfo, new StorageInfo(0));
    final ObjectAndPersistInfo objectAndItsClassInfo = objectStateMap
        .createObjectAndPersistInfoOfObject(bob1, false, bob1ClassInfo);
    objectAndItsClassInfo.setObjectStateMap(objectStateMap);
    final DataRecordIdentifier identifier = objectIOManager
        .getOrCreateDataRecordIdentifierAssociatedToObject(objectAndItsClassInfo);
    objectIOManager.prepareWrite(objectAndItsClassInfo);
    objectIOManager.write(objectAndItsClassInfo);

    // removedFromCandidateIdentifier = null;// NOPMD
View Full Code Here

TOP

Related Classes of net.sf.joafip.kvstore.record.entity.DataRecordIdentifier

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.