combined method

DeterministicSampler combined(
  1. double childRate
)

Returns a sampler that applies both this sampler's rate and childRate.

Use this when a feature has its own sample rate on top of the RUM session sample rate: for the same seed, anything sampled by the result is also sampled by this one.

Implementation

DeterministicSampler combined(double childRate) {
  return DeterministicSampler(
    samplingRate * (childRate.clamp(0.0, 100.0) / 100.0),
  );
}