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

decodes.decoder.TokenPosition Maven / Gradle / Ivy

Go to download

A collection of software for aggregatting and processing environmental data such as from NOAA GOES satellites.

The newest version!
package decodes.decoder;

/**
 * Encapsulates the position of a token within a string.
 * @author mmaloney
 *
 */
public class TokenPosition
{
	private int start=0, end=0;
	
	public TokenPosition() {}
	
	public TokenPosition(int start, int end)
	{
		this.start = start;
		this.end = end;
	}

	/**
	 * @return start position of the token
	 */
	public int getStart()
	{
		return start;
	}

	/**
	 * @return character position after the end of the token
	 */
	public int getEnd()
	{
		return end;
	}
	
	public String toString()
	{
		return "(" + start + ", " + end + ")";
	}

	public void setStart(int start)
	{
		this.start = start;
	}

	public void setEnd(int end)
	{
		this.end = end;
	}
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy