/*
 * Copyright The OpenTelemetry Authors
 * SPDX-License-Identifier: Apache-2.0
 */

package io.opentelemetry.contrib.sampler.consistent56;

/**
 * A function for generating random values.
 *
 * <p>The distribution of random values generated by this function must be uniform over the range
 * [0,2^56-1]
 */
@FunctionalInterface
public interface RandomValueGenerator {

  /**
   * Returns a 56-bit uniformly distributed random value.
   *
   * @param traceId the trace ID
   * @return the random value
   */
  long generate(String traceId);
}
