Interface DBIDs

    • Method Detail

      • iter

        DBIDIter iter()
        Get a DBID iterator (a more efficient API).

        Example:

         
         for(DBIDIter iter = ids.iter(); iter.valid(); iter.advance()) {
           NumberVector vec = relation.get(iter); // iter is a temporary object reference
         }
         
         
        Returns:
        iterator
      • size

        int size()
        Retrieve the collection / data size.
        Returns:
        collection size
      • contains

        boolean contains​(DBIDRef o)
        Test whether an ID is contained.
        Parameters:
        o - object to test
        Returns:
        true when contained
      • isEmpty

        default boolean isEmpty()
        Test for an empty DBID collection.
        Returns:
        true when empty.
      • forEach

        default void forEach​(java.util.function.Consumer<? super DBIDRef> action)
        Execute a function for each ID.
        Parameters:
        action - Action to execute