All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.daisy.dotify.common.splitter.StepForward Maven / Gradle / Ivy

The newest version!
package org.daisy.dotify.common.splitter;

/**
 * Provides a package interface for iterating over a list of units
 * @author Joel Håkansson
 *
 * @param 
 */
interface StepForward {
	/**
	 * Performed when a unit should be included.
	 * 
	 * @param unit the unit to include
	 */
	void addUnit(T unit);
	/**
	 * Checks whether the inclusion of the unit would overflow
	 *  
	 * @param buffer the unit to test
	 * @return returns true, if inclusion overflows, false otherwise
	 */
	boolean overflows(T buffer);
	/**
	 * Performed when a unit is discarded.
	 * 
	 * @param unit the unit that is discarded
	 */
	void addDiscarded(T unit);
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy