|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.luaj.vm2.Varargs
org.luaj.vm2.LuaValue
org.luaj.vm2.LuaString
public class LuaString
| Field Summary | |
|---|---|
byte[] |
m_bytes
|
int |
m_length
|
int |
m_offset
|
static LuaValue |
s_metatable
|
| Fields inherited from class org.luaj.vm2.LuaValue |
|---|
CALL, EMPTYSTRING, FALSE, INDEX, METATABLE, MINUSONE, MODE, NEWINDEX, NIL, NILS, NONE, NOVALS, ONE, TBOOLEAN, TFUNCTION, TINT, TLIGHTUSERDATA, TNIL, TNONE, TNUMBER, TRUE, TSTRING, TTABLE, TTHREAD, TUSERDATA, TVALUE, TYPE_NAMES, ZERO |
| Method Summary | |
|---|---|
LuaValue |
add(double lhs)
|
LuaValue |
add(LuaValue rhs)
|
int |
charAt(int index)
|
double |
checkdouble()
|
int |
checkint()
|
LuaInteger |
checkinteger()
|
java.lang.String |
checkjstring()
|
long |
checklong()
|
LuaNumber |
checknumber()
|
LuaNumber |
checknumber(java.lang.String msg)
|
LuaString |
checkstring()
|
java.lang.String |
concat_s(LuaValue rhs)
|
java.lang.String |
concatTo_s(java.lang.String lhs)
|
void |
copyInto(int strOffset,
byte[] bytes,
int arrayOffset,
int len)
Copy the bytes of the string into the given byte array. |
static java.lang.String |
decodeAsUtf8(byte[] bytes,
int offset,
int length)
Convert to Java String interpreting as utf8 characters |
LuaValue |
div(LuaValue rhs)
|
LuaValue |
divInto(double lhs)
|
static void |
encodeToUtf8(char[] chars,
byte[] bytes,
int off)
Encode the given Java string as UTF-8 bytes, writing the result to bytes starting at offset. |
boolean |
eq_b(LuaString s)
|
boolean |
eq_b(LuaValue val)
|
static boolean |
equals(byte[] a,
int i,
byte[] b,
int j,
int n)
|
static boolean |
equals(LuaString a,
int i,
LuaString b,
int j,
int n)
|
boolean |
equals(java.lang.Object o)
|
LuaValue |
get(LuaValue key)
|
LuaValue |
getmetatable()
|
boolean |
gt_b(double rhs)
|
boolean |
gt_b(int rhs)
|
boolean |
gt_b(LuaValue rhs)
|
LuaValue |
gt(LuaValue rhs)
|
boolean |
gteq_b(double rhs)
|
boolean |
gteq_b(int rhs)
|
boolean |
gteq_b(LuaValue rhs)
|
LuaValue |
gteq(LuaValue rhs)
|
int |
hashCode()
|
int |
indexOf(byte b,
int start)
|
int |
indexOf(LuaString s,
int start)
|
int |
indexOfAny(LuaString accept)
Java version of strpbrk, which is a terribly named C function. |
boolean |
isint()
|
boolean |
islong()
|
boolean |
isnumber()
|
boolean |
isstring()
|
boolean |
isValidUtf8()
|
int |
lastIndexOf(LuaString s)
|
LuaValue |
len()
|
int |
length()
|
static int |
lengthAsUtf8(char[] chars)
Count the number of bytes required to encode the string as UTF-8. |
boolean |
lt_b(double rhs)
|
boolean |
lt_b(int rhs)
|
boolean |
lt_b(LuaValue rhs)
|
LuaValue |
lt(LuaValue rhs)
|
boolean |
lteq_b(double rhs)
|
boolean |
lteq_b(int rhs)
|
boolean |
lteq_b(LuaValue rhs)
|
LuaValue |
lteq(LuaValue rhs)
|
int |
luaByte(int index)
|
LuaValue |
mod(LuaValue rhs)
|
LuaValue |
modFrom(double lhs)
|
LuaValue |
mul(double lhs)
|
LuaValue |
mul(int lhs)
|
LuaValue |
mul(LuaValue rhs)
|
LuaValue |
neg()
|
double |
optdouble(double defval)
|
int |
optint(int defval)
|
LuaInteger |
optinteger(LuaInteger defval)
|
java.lang.String |
optjstring(java.lang.String defval)
|
long |
optlong(long defval)
|
LuaNumber |
optnumber(LuaNumber defval)
|
LuaString |
optstring(LuaString defval)
|
LuaValue |
pow(LuaValue rhs)
|
LuaValue |
powWith(double lhs)
|
LuaValue |
powWith(int lhs)
|
int |
strcmp(LuaString rhs)
|
int |
strcmp(LuaValue lhs)
|
LuaString |
strvalue()
|
LuaValue |
sub(LuaValue rhs)
|
LuaValue |
subFrom(double lhs)
|
LuaString |
substring(int beginIndex,
int endIndex)
|
byte |
tobyte()
|
char |
tochar()
|
double |
todouble()
|
float |
tofloat()
|
java.io.InputStream |
toInputStream()
|
int |
toint()
|
java.lang.String |
tojstring()
|
long |
tolong()
|
LuaValue |
tonumber()
|
LuaValue |
tonumber(int base)
convert to a number using a supplied base, or NIL if it can't be converted |
short |
toshort()
|
LuaValue |
tostring()
|
int |
type()
|
java.lang.String |
typename()
|
static LuaString |
valueOf(byte[] bytes)
|
static LuaString |
valueOf(byte[] bytes,
int off,
int len)
|
static LuaString |
valueOf(char[] bytes)
|
static LuaString |
valueOf(java.lang.String string)
|
void |
write(java.io.DataOutputStream writer,
int i,
int len)
|
| Methods inherited from class org.luaj.vm2.Varargs |
|---|
argcheck, checkboolean, checkclosure, checkdouble, checkfunction, checkint, checkinteger, checkjstring, checklong, checknotnil, checknumber, checkstring, checkString, checktable, checkthread, checkuserdata, checkuserdata, checkvalue, eval, isfunction, isnil, isnoneornil, isnumber, isstring, istable, isTailcall, isthread, isuserdata, isvalue, optboolean, optclosure, optdouble, optfunction, optint, optinteger, optjstring, optlong, optnumber, optstring, optString, opttable, optthread, optuserdata, optuserdata, optvalue, subargs, toboolean, tobyte, tochar, todouble, tofloat, toint, tojstring, tolong, toshort, touserdata, touserdata, type |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static LuaValue s_metatable
public final byte[] m_bytes
public final int m_offset
public final int m_length
| Method Detail |
|---|
public static LuaString valueOf(java.lang.String string)
public static LuaString valueOf(byte[] bytes,
int off,
int len)
public static LuaString valueOf(char[] bytes)
public static LuaString valueOf(byte[] bytes)
public boolean isstring()
isstring in class LuaValuepublic LuaValue getmetatable()
getmetatable in class LuaValuepublic int type()
type in class LuaValuepublic java.lang.String typename()
typename in class LuaValuepublic java.lang.String tojstring()
tojstring in class LuaValuepublic LuaValue get(LuaValue key)
get in class LuaValuepublic LuaValue neg()
neg in class LuaValuepublic LuaValue add(LuaValue rhs)
add in class LuaValuepublic LuaValue add(double lhs)
add in class LuaValuepublic LuaValue sub(LuaValue rhs)
sub in class LuaValuepublic LuaValue subFrom(double lhs)
subFrom in class LuaValuepublic LuaValue mul(LuaValue rhs)
mul in class LuaValuepublic LuaValue mul(double lhs)
mul in class LuaValuepublic LuaValue mul(int lhs)
mul in class LuaValuepublic LuaValue pow(LuaValue rhs)
pow in class LuaValuepublic LuaValue powWith(double lhs)
powWith in class LuaValuepublic LuaValue powWith(int lhs)
powWith in class LuaValuepublic LuaValue div(LuaValue rhs)
div in class LuaValuepublic LuaValue divInto(double lhs)
divInto in class LuaValuepublic LuaValue mod(LuaValue rhs)
mod in class LuaValuepublic LuaValue modFrom(double lhs)
modFrom in class LuaValuepublic LuaValue lt(LuaValue rhs)
lt in class LuaValuepublic boolean lt_b(LuaValue rhs)
lt_b in class LuaValuepublic boolean lt_b(int rhs)
lt_b in class LuaValuepublic boolean lt_b(double rhs)
lt_b in class LuaValuepublic LuaValue lteq(LuaValue rhs)
lteq in class LuaValuepublic boolean lteq_b(LuaValue rhs)
lteq_b in class LuaValuepublic boolean lteq_b(int rhs)
lteq_b in class LuaValuepublic boolean lteq_b(double rhs)
lteq_b in class LuaValuepublic LuaValue gt(LuaValue rhs)
gt in class LuaValuepublic boolean gt_b(LuaValue rhs)
gt_b in class LuaValuepublic boolean gt_b(int rhs)
gt_b in class LuaValuepublic boolean gt_b(double rhs)
gt_b in class LuaValuepublic LuaValue gteq(LuaValue rhs)
gteq in class LuaValuepublic boolean gteq_b(LuaValue rhs)
gteq_b in class LuaValuepublic boolean gteq_b(int rhs)
gteq_b in class LuaValuepublic boolean gteq_b(double rhs)
gteq_b in class LuaValuepublic java.lang.String concat_s(LuaValue rhs)
concat_s in class LuaValuepublic java.lang.String concatTo_s(java.lang.String lhs)
concatTo_s in class LuaValuepublic int strcmp(LuaValue lhs)
strcmp in class LuaValuepublic int strcmp(LuaString rhs)
strcmp in class LuaValuepublic int checkint()
checkint in class LuaValuepublic LuaInteger checkinteger()
checkinteger in class LuaValuepublic long checklong()
checklong in class LuaValuepublic double checkdouble()
checkdouble in class LuaValuepublic LuaNumber checknumber()
checknumber in class LuaValuepublic LuaNumber checknumber(java.lang.String msg)
checknumber in class LuaValuepublic LuaValue tonumber()
tonumber in class LuaValuepublic boolean isnumber()
isnumber in class LuaValuepublic boolean isint()
isint in class LuaValuepublic boolean islong()
islong in class LuaValuepublic byte tobyte()
tobyte in class LuaValuepublic char tochar()
tochar in class LuaValuepublic double todouble()
todouble in class LuaValuepublic float tofloat()
tofloat in class LuaValuepublic int toint()
toint in class LuaValuepublic long tolong()
tolong in class LuaValuepublic short toshort()
toshort in class LuaValuepublic double optdouble(double defval)
optdouble in class LuaValuepublic int optint(int defval)
optint in class LuaValuepublic LuaInteger optinteger(LuaInteger defval)
optinteger in class LuaValuepublic long optlong(long defval)
optlong in class LuaValuepublic LuaNumber optnumber(LuaNumber defval)
optnumber in class LuaValuepublic LuaString optstring(LuaString defval)
optstring in class LuaValuepublic LuaValue tostring()
tostring in class LuaValuepublic java.lang.String optjstring(java.lang.String defval)
optjstring in class LuaValuepublic LuaString strvalue()
strvalue in class LuaValue
public LuaString substring(int beginIndex,
int endIndex)
public int hashCode()
hashCode in class java.lang.Objectpublic boolean equals(java.lang.Object o)
equals in class LuaValuepublic boolean eq_b(LuaString s)
eq_b in class LuaValuepublic boolean eq_b(LuaValue val)
eq_b in class LuaValue
public static boolean equals(LuaString a,
int i,
LuaString b,
int j,
int n)
public static boolean equals(byte[] a,
int i,
byte[] b,
int j,
int n)
public void write(java.io.DataOutputStream writer,
int i,
int len)
throws java.io.IOException
java.io.IOExceptionpublic LuaValue len()
len in class LuaValuepublic int length()
length in class LuaValuepublic int luaByte(int index)
public int charAt(int index)
public java.lang.String checkjstring()
checkjstring in class LuaValuepublic LuaString checkstring()
checkstring in class LuaValuepublic java.io.InputStream toInputStream()
public void copyInto(int strOffset,
byte[] bytes,
int arrayOffset,
int len)
public int indexOfAny(LuaString accept)
public int indexOf(byte b,
int start)
public int indexOf(LuaString s,
int start)
public int lastIndexOf(LuaString s)
public static java.lang.String decodeAsUtf8(byte[] bytes,
int offset,
int length)
public static int lengthAsUtf8(char[] chars)
public static void encodeToUtf8(char[] chars,
byte[] bytes,
int off)
public boolean isValidUtf8()
public LuaValue tonumber(int base)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||