Class TwoStepsGOV3Function.Builder<T>

    • Field Detail

      • keys

        protected java.lang.Iterable<? extends T> keys
      • transform

        protected it.unimi.dsi.bits.TransformationStrategy<? super T> transform
      • tempDir

        protected java.io.File tempDir
      • values

        protected it.unimi.dsi.fastutil.longs.LongBigList values
      • built

        protected boolean built
        Whether build() has already been called.
    • Constructor Detail

      • Builder

        public Builder()
    • Method Detail

      • keys

        public TwoStepsGOV3Function.Builder<T> keys​(java.lang.Iterable<? extends T> keys)
        Specifies the keys of the function; if you have specified a BucketedHashStore, it can be null.
        Parameters:
        keys - the keys of the function.
        Returns:
        this builder.
      • store

        public TwoStepsGOV3Function.Builder<T> store​(BucketedHashStore<T> bucketedHashStore)
        Specifies a bucketed hash store containing the keys associated with their rank.

        Warning: during the construction phase, a filter will be set on the specified BucketedHashStore. You will have to reset it to its previous state.

        Parameters:
        bucketedHashStore - a bucketed hash store containing the keys associated with their rank, or null; the store can be unchecked, but in this case you must specify keys and a transform (otherwise, in case of a hash collision in the store an IllegalStateException will be thrown).
        Returns:
        this builder.
      • values

        public TwoStepsGOV3Function.Builder<T> values​(it.unimi.dsi.fastutil.longs.LongBigList values)
        Specifies the values assigned to the keys; the output width of the function will be the minimum width needed to represent all values.
        Parameters:
        values - values to be assigned to each element, in the same order of the keys.
        Returns:
        this builder.
      • build

        public TwoStepsGOV3Function<T> build()
                                      throws java.io.IOException
        Builds a new function.
        Returns:
        a GOV3Function instance with the specified parameters.
        Throws:
        java.lang.IllegalStateException - if called more than once.
        java.io.IOException