SampleType - type of the sample that is stored in this object.public final class SampleWithSizeEstimate<SampleType extends Sample> extends Object
| Constructor and Description | 
|---|
SampleWithSizeEstimate(SampleType sample,
                      int estimatedSampleSize)
Creates a pair that stored the specified sample and estimated size. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
boolean | 
equals(Object obj)  | 
int | 
getEstimatedSampleSize()
Returns the estimated size of the sample that is returned by
  
getSample(). | 
SampleType | 
getSample()
Returns the sample that is supposed to be written. 
 | 
int | 
hashCode()  | 
String | 
toString()  | 
public SampleWithSizeEstimate(SampleType sample, int estimatedSampleSize)
sample - sample that is supposed to be written.estimatedSampleSize - estimated size of the specified sample when serialized into
            the database (in bytes). This information is used by the
            archiving code to keep track of the total size of the samples
            that are stored inside a bucket. As storing too much (or too
            little) data in a single bucket has an impact on performance,
            the archiving code will decide to start a new bucket when a
            certain size has been reached. Therefore, this estimate should
            be as accurate as possible. Must not be negative.IllegalArgumentException - if estimatedSampleSize is negative.NullPointerException - if sample is null.public int getEstimatedSampleSize()
getSample(). The size is specified in bytes. This information is
 used by the archiving code to keep track of the total size of the samples
 that are stored inside a bucket.public SampleType getSample()
Copyright © 2011–2017 aquenos GmbH. All rights reserved.