summaryrefslogtreecommitdiff
path: root/JPratt/src/main/java/com/ashardalon/pratt/tokens/Token.java
blob: 86f0d05608e48aac4788a54c7f0b8574eab58323 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
package com.ashardalon.pratt.tokens;

/**
 * Represents a simple parsing token.
 *
 * @author EVE
 *
 * @param <K>
 *        The key type of this token. Represents the type of the token.
 *
 * @param <V>
 *        The value type of this token. Represents any additional data for the
 *        token.
 *
 */
public interface Token<K, V> {
	/**
	 * Get the key for this token.
	 *
	 * @return The key for this token
	 */
	K getKey();

	/**
	 * Get the value for this token.
	 *
	 * @return The value for this token.
	 */
	V getValue();
}