Package elki.database

Class ProxyDatabase

  • All Implemented Interfaces:
    Database

    public class ProxyDatabase
    extends AbstractDatabase
    A proxy database to use, e.g., for projections and partitions.
    Since:
    0.4.0
    Author:
    Erich Schubert
    • Field Detail

      • LOG

        private static final Logging LOG
        Logger class.
      • idrep

        protected DBIDView idrep
        Our DBID representation
    • Constructor Detail

      • ProxyDatabase

        public ProxyDatabase​(DBIDs ids)
        Constructor.
        Parameters:
        ids - DBIDs to use
      • ProxyDatabase

        public ProxyDatabase​(DBIDs ids,
                             java.lang.Iterable<Relation<?>> relations)
        Constructor.
        Parameters:
        ids - DBIDs to use
        relations - Relations to contain
      • ProxyDatabase

        public ProxyDatabase​(DBIDs ids,
                             Relation<?>... relations)
        Constructor.
        Parameters:
        ids - DBIDs to use
        relations - Relations to contain
      • ProxyDatabase

        public ProxyDatabase​(DBIDs ids,
                             Database database)
        Constructor, proxying all relations of an existing database.
        Parameters:
        ids - ids to proxy
        database - Database to wrap
    • Method Detail

      • initialize

        public void initialize()
        Description copied from interface: Database
        Initialize the database, for example by loading the input data. (Since this should NOT be done on construction time!)
      • addRelation

        public void addRelation​(Relation<?> relation)
        Add a new representation.
        Parameters:
        relation - Representation to add.
      • setDBIDs

        public void setDBIDs​(DBIDs ids)
        Set the DBIDs to use.
        Parameters:
        ids - DBIDs to use