Interface IDataset

All Known Implementing Classes:
TabulatedDataset

public interface IDataset
Interface for classes that will contain one or more indexed objects implementing IRecordHolder.

Dataset's directly equivalent sources might include, e.g. directories where the contained files are the record holders to be, or a database holding tables.

Author:
Andy Evans
Version: 1.0 01 Mar 2021
  • Method Details

    • setMetadata

      void setMetadata​(IMetadata metadata)
      Should set the metadata for this IDataset.
      Parameters:
      metadata - The metadata object for this IDataset.
    • getMetadata

      IMetadata getMetadata()
      Should get the metadata for this IDataset.
      Returns:
      IMetadata The metadata object for this IDataset.
    • setEstimatedRecordCount

      void setEstimatedRecordCount​(int estimatedRecordCount)
      Should set the total records held - or to be held - in this dataset.

      For data streaming this may be a calculation of the estimated number of records to be held rather than the actual records, hence the name.

      Parameters:
      estimatedRecordCount - Number of records or estimate.
    • getEstimatedRecordCount

      int getEstimatedRecordCount()
      Should get the total records held - or to be held - in this dataset.

      For data streaming this may be a calculation of the estimated number of records to be held rather than the actual records, hence the name - it should only be used for processing progress estimations, not drawing on data. For the latter, use getRecordHolders().getRecords().get(i).size().

      Returns:
      int Number of records or estimate.
    • setRecordHolder

      void setRecordHolder​(int index, IRecordHolder recordHolder)
      Should set a single RecordHolder at an index.
      Parameters:
      index - Location to add RecordHolder.
      recordHolder - RecordHolder to add.
    • addRecordHolder

      void addRecordHolder​(IRecordHolder recordHolder)
      Should add a single RecordHolder to the end of the container.
      Parameters:
      recordHolder - RecordHolder to add.
    • addRecordHolders

      void addRecordHolders​(ArrayList<IRecordHolder> recordHolders)
      Should add a collection of IRecordHolder objects to the end of the container.
      Parameters:
      recordHolders - Record holders to add.
    • getRecordHolder

      IRecordHolder getRecordHolder​(int index)
      Should get a single RecordHolder at an index.
      Parameters:
      index - Location of RecordHolder.
      Returns:
      IRecordHolder RecordHolder requested.
    • getRecordHolders

      ArrayList<IRecordHolder> getRecordHolders()
      Should get all RecordHolder objects.
      Returns:
      ArrayList All RecordHolder as a collection.