Builds an LCP monotone minimal perfect hash function.

@return an {@link LcpMonotoneMinimalPerfectHashFunction} instance with the specified parameters.
@throws IllegalStateException if called more than once.
349232
public LcpMonotoneMinimalPerfectHashFunction<T> build() throws IOException {
			if (built) throw new IllegalStateException("This builder has been already used");
			built = true;
			return new LcpMonotoneMinimalPerfectHashFunction<>(keys, numKeys, transform, signatureWidth, tempDir);
		}
816415
public static <K, V> HashBiMap<K, V> create(int expectedSize) {
    return new HashBiMap<K, V>(expectedSize);
  }
628182
public HashAlgorithm getDecodedHashAlgorithm() throws TLVParserException {
        int algorithmId = getDecodedLong().intValue();
        if (HashAlgorithm.isHashAlgorithmId(algorithmId)) {
            return HashAlgorithm.getById(algorithmId);
        }
        throw new TLVParserException("Unknown hash algorithm with id " + algorithmId);
    }
1021642
def hash(self):
        '''
        
        '''
        hashed = super(TakeFrom, self).hash()
        return khash(hashed, self.min_elements, self.max_elements, self.seed)
136664
private static int hashCapacity(int min) {
        BigInteger capacity = BigInteger.valueOf(min * 2 + 1);
        while (!capacity.isProbablePrime(10)) {
            capacity = capacity.add(BigInteger.valueOf(2));
        }
        return capacity.intValue();
    }
1235449
public com.google.privacy.dlp.v2.CryptoHashConfig getCryptoHashConfig() {
    if (transformationCase_ == 9) {
      return (com.google.privacy.dlp.v2.CryptoHashConfig) transformation_;
    }
    return com.google.privacy.dlp.v2.CryptoHashConfig.getDefaultInstance();
  }
1267337
static HeapUpdateDoublesSketch newInstance(final int k) {
    final HeapUpdateDoublesSketch hqs = new HeapUpdateDoublesSketch(k);
    final int baseBufAlloc = 2 * Math.min(DoublesSketch.MIN_K, k); //the min is important
    hqs.n_ = 0;
    hqs.combinedBuffer_ = new double[baseBufAlloc];
    hqs.baseBufferCount_ = 0;
    hqs.bitPattern_ = 0;
    hqs.minValue_ = Double.NaN;
    hqs.maxValue_ = Double.NaN;
    return hqs;
  }
890644
@Override
	public BarrierFunction createPhase1BarrierFunction(){
		
		final int dimPh1 = dim +1;
		List<SOCPConstraintParameters> socpConstraintParametersPh1List = new ArrayList<SOCPConstraintParameters>();
 		SOCPLogarithmicBarrier bfPh1 = new SOCPLogarithmicBarrier(socpConstraintParametersPh1List, dimPh1);
 		
 		for(int i=0; i<socpConstraintParametersList.size(); i++){
 			SOCPConstraintParameters param = socpConstraintParametersList.get(i);
 			RealMatrix A = param.getA();
 			RealVector b = param.getB();
 			RealVector c = param.getC();
 			double d = param.getD();
 			
 			RealMatrix APh1 = MatrixUtils.createRealMatrix(A.getRowDimension(), dimPh1);
 			APh1.setSubMatrix(A.getData(), 0, 0); 
			RealVector bPh1 = b;
			RealVector cPh1 = new ArrayRealVector(c.getDimension()+1);
			cPh1.setSubVector(0, c);
			cPh1.setEntry(c.getDimension(), 1);
	 		double dPh1 = d;
	 		
	 		SOCPConstraintParameters paramsPh1 = new SOCPConstraintParameters(APh1.getData(), bPh1.toArray(), cPh1.toArray(), dPh1);
	 		socpConstraintParametersPh1List.add(socpConstraintParametersPh1List.size(), paramsPh1);
		}
		
		return bfPh1;
	}
368140
@Nonnull
    public <B> HashTable<K, B> toHashTable(@Nonnull F<ImmutableList<V>, B> conversion) {
        //return this.data.foldLeft((acc, p) -> acc.put(p.a, conversion.apply(p.b)), HashTable.empty(this.data.hasher));
        return this.toHashTable((k, vs) -> conversion.apply(vs));
    }
1093418
public final Checksum asChecksum() {
    return new Checksum() {

      @Override
      public long getValue() {
        return StreamingXXHash32.this.getValue() & 0xFFFFFFFL;
      }

      @Override
      public void reset() {
        StreamingXXHash32.this.reset();
      }

      @Override
      public void update(int b) {
        StreamingXXHash32.this.update(new byte[] {(byte) b}, 0, 1);
      }

      @Override
      public void update(byte[] b, int off, int len) {
        StreamingXXHash32.this.update(b, off, len);
      }

      @Override
      public String toString() {
        return StreamingXXHash32.this.toString();
      }

    };
  }
290232
@Override
    protected ImmutableMap<Class<? extends QueryOptimizationProposal>, Class<? extends ProposalExecutor>>
    generateOptimizationConfigurationMap() {
        ImmutableMap.Builder<Class<? extends QueryOptimizationProposal>, Class<? extends ProposalExecutor>>
                internalExecutorMapBuilder = ImmutableMap.builder();
        internalExecutorMapBuilder.putAll(super.generateOptimizationConfigurationMap());

        internalExecutorMapBuilder.put(InnerJoinOptimizationProposal.class, InnerJoinExecutor.class);
        internalExecutorMapBuilder.put(SubstitutionPropagationProposal.class, SubstitutionPropagationExecutor.class);
        internalExecutorMapBuilder.put(PushDownBooleanExpressionProposal.class, PushDownBooleanExpressionExecutor.class);
        internalExecutorMapBuilder.put(PushUpBooleanExpressionProposal.class, PushUpBooleanExpressionExecutor.class);
        internalExecutorMapBuilder.put(UnionLiftProposal.class, UnionLiftExecutor.class);
        internalExecutorMapBuilder.put(LeftJoinOptimizationProposal.class, LeftJoinExecutor.class);
        internalExecutorMapBuilder.put(ProjectionShrinkingProposal.class, ProjectionShrinkingExecutor.class);
        internalExecutorMapBuilder.put(FlattenUnionProposal.class, FlattenUnionExecutor.class);
        internalExecutorMapBuilder.put(ConstructionNodeCleaningProposal.class, ConstructionNodeCleaningExecutor.class);
        return internalExecutorMapBuilder.build();
    }
683194
@Override
  public Hash2<Integer, V> createHashTable() {
    return new Hash2<Integer, V>(this) {
      @Override
      protected int modifiedHashCode(final int hc) {
        return IntHeapCache.this.modifiedHash(hc);
      }

      @Override
      protected boolean keyObjIsEqual(final Integer key, final Entry e) {
        return true;
      }
    };
  }
377668
public TableKeysAndAttributes withHashOnlyKeys(String hashKeyName, Object ... hashKeyValues) {
        if (hashKeyName == null)
            throw new IllegalArgumentException();
        PrimaryKey[] primaryKeys = new PrimaryKey[hashKeyValues.length];
        for (int i=0; i < hashKeyValues.length; i++)
            primaryKeys[i] = new PrimaryKey(hashKeyName, hashKeyValues[i]);
        return withPrimaryKeys(primaryKeys);
    }
975112
@Nonnull
	public final LBiCharFunction<R> build() {

		final LBiCharFunction<R> eventuallyFinal = this.eventually;

		LBiCharFunction<R> retval;

		final Case<LBiCharPredicate, LBiCharFunction<R>>[] casesArray = cases.toArray(new Case[cases.size()]);
		retval = LBiCharFunction.<R> biCharFunc((a1, a2) -> {
			try {
				for (Case<LBiCharPredicate, LBiCharFunction<R>> aCase : casesArray) {
					if (aCase.casePredicate().test(a1, a2)) {
						return aCase.caseFunction().apply(a1, a2);
					}
				}

				return eventuallyFinal.apply(a1, a2);
			} catch (Error e) { // NOSONAR
					throw e;
				} catch (Throwable e) { // NOSONAR
					throw Handler.handleOrPropagate(e, handling);
				}
			});

		if (consumer != null) {
			consumer.accept(retval);
		}
		return retval;
	}
780972
public int[] hash(Key k){
      byte[] b = k.getBytes();
      if (b == null) {
        throw new NullPointerException("buffer reference is null");
      }
      if (b.length == 0) {
        throw new IllegalArgumentException("key length must be > 0");
      }
      int[] result = new int[nbHash];
      for (int i = 0, initval = 0; i < nbHash; i++) {
	  initval = hashFunction.hash(b, initval);
	  result[i] = Math.abs(initval % maxValue);
      }
      return result;
  }
56504
static final CompactSketch createCompactSketch(final long[] compactCache, boolean empty,
      final short seedHash, final int curCount, long thetaLong, final boolean dstOrdered,
      final WritableMemory dstMem) {
    thetaLong = thetaOnCompact(empty, curCount, thetaLong);
    empty = emptyOnCompact(curCount, thetaLong);

    CompactSketch sketchOut = null;
    final int sw = (dstOrdered ? 2 : 0) | ((dstMem != null) ? 1 : 0);
    switch (sw) {
      case 0: { //dst not ordered, dstMem == null
        sketchOut = HeapCompactUnorderedSketch.compact(compactCache, empty, seedHash, curCount,
            thetaLong); //converts to SingleItem if curCount == 1
        break;
      }
      case 1: { //dst not ordered, dstMem == valid
        sketchOut = DirectCompactUnorderedSketch.compact(compactCache, empty, seedHash, curCount,
            thetaLong, dstMem); //converts to SingleItem format if curCount == 1
        break;
      }
      case 2: { //dst ordered, dstMem == null
        sketchOut = HeapCompactOrderedSketch.compact(compactCache, empty, seedHash, curCount,
            thetaLong); //converts to SingleItem format if curCount == 1
        break;
      }
      case 3: { //dst ordered, dstMem == valid
        sketchOut = DirectCompactOrderedSketch.compact(compactCache, empty, seedHash, curCount,
            thetaLong, dstMem); //converts to SingleItem format if curCount == 1
        break;
      }
      //default: //This cannot happen and cannot be tested
    }
    return sketchOut;
  }
987639
public static <S> PVolumeBDGenerator<S> create()
  {
    return new PVolumeBDGenerator<>(new Generator<BigDecimal>()
    {
      private final Random random = new Random();

      @Override
      public BigDecimal next()
      {
        return BigDecimal.valueOf(Math.abs(this.random.nextLong()));
      }
    });
  }