Class NoMoreTimestampsStopCondition<U extends java.io.Serializable,I extends java.io.Serializable,F>
java.lang.Object
es.uam.eps.ir.relison.diffusion.stop.NoMoreTimestampsStopCondition<U,I,F>
- Type Parameters:
U
- type of the users.I
- type of the information pieces.F
- type of the user and information pieces features.
- All Implemented Interfaces:
StopCondition<U,I,F>
public class NoMoreTimestampsStopCondition<U extends java.io.Serializable,I extends java.io.Serializable,F> extends java.lang.Object implements StopCondition<U,I,F>
Stop condition: when the last timestamp has appeared, then, stop.
-
Constructor Summary
Constructors Constructor Description NoMoreTimestampsStopCondition()
-
Method Summary
-
Constructor Details
-
NoMoreTimestampsStopCondition
public NoMoreTimestampsStopCondition()
-
-
Method Details
-
stop
public boolean stop(int numIter, int numPropagated, int propagatingUsers, long newlyPropagated, long totalPropagated, Data<U,I,F> data, java.lang.Long timestamp)Description copied from interface:StopCondition
Checks the stop condition.- Specified by:
stop
in interfaceStopCondition<U extends java.io.Serializable,I extends java.io.Serializable,F>
- Parameters:
numIter
- the current number of iterations.numPropagated
- the number of information pieces which has been propagated during this iteration.propagatingUsers
- the number of users who propagate information.newlyPropagated
- the number of information pieces which have been seen this iteration.totalPropagated
- the total number of information pieces which have been propagated during the simulation.data
- the simulation data.timestamp
- the timestamp corresponding to the current iteration.- Returns:
- true if the simulator has to stop, false if not.
-