Class Source
java.lang.Object
org.apache.commons.jexl3.internal.Source
- All Implemented Interfaces:
Comparable<Source>
Maintains the set of allowed features associated with a script/expression source.
This is meant for caching scripts using their 'source' as key but still distinguishing scripts with different features and prevent false sharing.
-
Field Details
-
hashCode
private final int hashCodeThe hash code, pre-computed for fast op. -
features
The set of features. -
symbols
The local symbols, if any. -
str
The actual source script/expression.
-
-
Constructor Details
-
Source
Source(JexlFeatures theFeatures, Map<String, Integer> theSymbols, String theStr) Default constructor.- Parameters:
theFeatures- The featurestheSymbols- The map of variable name to symbol offset in evaluation frametheStr- The script source
-
-
Method Details
-
compareTo
- Specified by:
compareToin interfaceComparable<Source>
-
equals
-
getFeatures
- Returns:
- The features associated with the source
-
hashCode
public int hashCode() -
length
int length()- Returns:
- The length of the script source
-
toString
-