Class IndexWrapper

java.lang.Object
org.apache.jena.tdb1.index.IndexWrapper
All Implemented Interfaces:
Iterable<Record>, org.apache.jena.atlas.lib.Closeable, org.apache.jena.atlas.lib.Sync, Index
Direct Known Subclasses:
IndexLogger

public class IndexWrapper extends Object implements Index
  • Constructor Details

    • IndexWrapper

      public IndexWrapper(Index idx)
  • Method Details

    • find

      public Record find(Record record)
      Description copied from interface: Index
      Find one record - and return the record actually in the index (may have a value part)
      Specified by:
      find in interface Index
    • contains

      public boolean contains(Record record)
      Description copied from interface: Index
      Return whether the index contains the record or not.
      Specified by:
      contains in interface Index
    • add

      public boolean add(Record record)
      Description copied from interface: Index
      Add a record - return true if an insertion was actually needed
      Specified by:
      add in interface Index
    • delete

      public boolean delete(Record record)
      Description copied from interface: Index
      Delete a record. Return true if a record was actually removed
      Specified by:
      delete in interface Index
    • iterator

      public Iterator<Record> iterator()
      Description copied from interface: Index
      Iterate over the whole index
      Specified by:
      iterator in interface Index
      Specified by:
      iterator in interface Iterable<Record>
    • isEmpty

      public boolean isEmpty()
      Description copied from interface: Index
      Answer whether the index is empty or not. May return false for unknown or meaningless
      Specified by:
      isEmpty in interface Index
    • clear

      public void clear()
      Description copied from interface: Index
      Clear the index
      Specified by:
      clear in interface Index
    • sync

      public void sync()
      Specified by:
      sync in interface org.apache.jena.atlas.lib.Sync
    • close

      public void close()
      Description copied from interface: Index
      Close the index - can not be used again through this object
      Specified by:
      close in interface org.apache.jena.atlas.lib.Closeable
      Specified by:
      close in interface Index
    • getRecordFactory

      public RecordFactory getRecordFactory()
      Description copied from interface: Index
      Get the Record factory associated with this index
      Specified by:
      getRecordFactory in interface Index
    • check

      public void check()
      Description copied from interface: Index
      Perform checks on this index
      Specified by:
      check in interface Index
    • size

      public long size()
      Description copied from interface: Index
      Return size if known else return -1 : does not count the persistent storage
      Specified by:
      size in interface Index