Jalog 1.4
java.lang.Object io.github.JalogTeam.jalog.Pro_TermData io.github.JalogTeam.jalog.Pro_TermData_String
public abstract class Pro_TermData_String
Note: Don't use this class unless you need some operations or fields that the class Pro_Term
does not provide.
String constants are represented as
Pro_TermData_String
objects.
All character indices start from 0.
Field Summary | |
---|---|
long |
len
Number of characters |
String |
typename
The type of this term. This is always set to Jalog.STRING . Do not change! (Inherited from parent.)
|
Method Summary | |
---|---|
static int
|
compare_strings(Pro_TermData_String s1,
Pro_TermData_String s2)
Compares the strings. |
static boolean
|
contains_at(Pro_TermData_String s1, long pos,
Pro_TermData_String s2)
Returns true if the string s1 contains at pos a substring that is equal to s2 .
|
Pro_TermData
|
copy(Hashtable variable_map)
Returns this object. (Inherited from parent.)
|
abstract String
|
image()
Returns human readable string representation of this term, i.e. the value of this as a Java String object.
|
String
|
substring(long start, long len)
Returns the selected part of the string as a Java String .
|
String
|
toString()
Returns Jalog syntax representation of this term. |
Field Detail |
---|
public long len
Method Detail |
---|
public static int compare_strings(Pro_TermData_String s1, Pro_TermData_String s2)
Strings are compared from the beginning by character codes. If the strings are equal zero is returned. A negative integer is returned if the first string precedes the second string in the character code order. Otherwise a positive integer is returned.
s1
- the first string
s2
- the second string
public static boolean contains_at(Pro_TermData_String s1, long pos, Pro_TermData_String s2)
true
if the string s1
contains at pos
a substring that is equal to s2
.
s1
- possibly containing string
pos
- zero based position index
s2
- possible substring
true
if contains
public String image()
write
.
String
public abstract String substring(long start, long len)
String
. If start
is negative or len
is too large, the result string is shorter than len
.
start
- zero based index to first character to include
len
- number of characters to include
String
.
public String toString()
\
”.