* <p>
* Implement me. Please.
*/
-public class TmfEventRequest<T extends TmfEvent> extends TmfDataRequest<T> {
+public abstract class TmfEventRequest<T extends TmfEvent> extends TmfDataRequest<T> implements ITmfEventRequest<T> {
// ------------------------------------------------------------------------
// Attributes
/**
* @param range
*/
- public TmfEventRequest(Class<? extends TmfEvent> dataType) {
+ public TmfEventRequest(Class<T> dataType) {
this(dataType, TmfTimeRange.Eternity, ALL_DATA, DEFAULT_BLOCK_SIZE);
}
/**
* @param range
*/
- public TmfEventRequest(Class<? extends TmfEvent> dataType, TmfTimeRange range) {
+ public TmfEventRequest(Class<T> dataType, TmfTimeRange range) {
this(dataType, range, ALL_DATA, DEFAULT_BLOCK_SIZE);
}
* @param range
* @param nbRequested
*/
- public TmfEventRequest(Class<? extends TmfEvent> dataType, TmfTimeRange range, int nbRequested) {
+ public TmfEventRequest(Class<T> dataType, TmfTimeRange range, int nbRequested) {
this(dataType, range, nbRequested, DEFAULT_BLOCK_SIZE);
}
* @param nbRequested
* @param blockSize Size of the largest blocks expected
*/
- public TmfEventRequest(Class<? extends TmfEvent> dataType, TmfTimeRange range, int nbRequested, int blockSize) {
+ public TmfEventRequest(Class<T> dataType, TmfTimeRange range, int nbRequested, int blockSize) {
super(dataType, 0, nbRequested, blockSize);
fRange = range;
}
+ @Override
+ public boolean equals(Object other) {
+ if (other instanceof TmfEventRequest<?>) {
+ TmfEventRequest<?> request = (TmfEventRequest<?>) other;
+ return super.equals(other) && request.fRange.equals(fRange);
+ }
+ return false;
+ }
+
// ------------------------------------------------------------------------
// Accessors
// ------------------------------------------------------------------------