public abstract class Value
extends java.lang.Object
implements java.io.Serializable
Modifier and Type | Field and Description |
---|---|
protected static L10N |
L |
static Value[] |
NULL_ARGS |
static Value[] |
NULL_VALUE_ARRAY |
Constructor and Description |
---|
Value() |
Modifier and Type | Method and Description |
---|---|
Value |
abs()
Absolute value.
|
Value |
add(long lLong)
Multiplies to the following value.
|
Value |
add(Value rValue)
Adds to the following value.
|
Value |
addOne()
Return the next integer
|
Value |
append(Value index,
Value value)
Sets the array value, returning the new array, e.g.
|
StringValue |
appendTo(BinaryBuilderValue sb)
Append to a binary builder.
|
StringValue |
appendTo(LargeStringBuilderValue sb)
Append to a binary builder.
|
StringValue |
appendTo(StringBuilderValue sb)
Append to a binary builder.
|
StringValue |
appendTo(UnicodeBuilderValue sb)
Append to a string builder.
|
Value |
bitAnd(Value rValue) |
Value |
bitOr(Value rValue) |
Value |
bitXor(Value rValue)
Binary xor.
|
Value |
call(Env env)
Evaluates the function.
|
Value |
call(Env env,
Value a1)
Evaluates the function with an argument .
|
Value |
call(Env env,
Value[] args)
Evaluates the function.
|
Value |
call(Env env,
Value a1,
Value a2)
Evaluates the function with arguments
|
Value |
call(Env env,
Value a1,
Value a2,
Value a3)
Evaluates the function with arguments
|
Value |
call(Env env,
Value a1,
Value a2,
Value a3,
Value a4)
Evaluates the function with arguments
|
Value |
call(Env env,
Value a1,
Value a2,
Value a3,
Value a4,
Value a5)
Evaluates the function with arguments
|
Value |
callCopy(Env env,
Value[] args)
Evaluates the function, returning a copy
|
Value |
callMethod(Env env,
StringValue methodName)
Evaluates a method with 0 args.
|
Value |
callMethod(Env env,
StringValue methodName,
int hash)
Evaluates a method with 0 args.
|
Value |
callMethod(Env env,
StringValue methodName,
int hash,
Value a1)
Evaluates a method with 1 arg.
|
Value |
callMethod(Env env,
StringValue methodName,
int hash,
Value[] args)
Evaluates a method.
|
Value |
callMethod(Env env,
StringValue methodName,
int hash,
Value a1,
Value a2)
Evaluates a method with 2 args.
|
Value |
callMethod(Env env,
StringValue methodName,
int hash,
Value a1,
Value a2,
Value a3)
Evaluates a method with 3 args.
|
Value |
callMethod(Env env,
StringValue methodName,
int hash,
Value a1,
Value a2,
Value a3,
Value a4)
Evaluates a method with 4 args.
|
Value |
callMethod(Env env,
StringValue methodName,
int hash,
Value a1,
Value a2,
Value a3,
Value a4,
Value a5)
Evaluates a method with 5 args.
|
Value |
callMethod(Env env,
StringValue methodName,
Value a1)
Evaluates a method with 1 arg.
|
Value |
callMethod(Env env,
StringValue methodName,
Value[] args)
Evaluates a method.
|
Value |
callMethod(Env env,
StringValue methodName,
Value a1,
Value a2)
Evaluates a method with 2 args.
|
Value |
callMethod(Env env,
StringValue methodName,
Value a1,
Value a2,
Value a3)
Evaluates a method with 3 args.
|
Value |
callMethod(Env env,
StringValue methodName,
Value a1,
Value a2,
Value a3,
Value a4)
Evaluates a method with 4 args.
|
Value |
callMethod(Env env,
StringValue methodName,
Value a1,
Value a2,
Value a3,
Value a4,
Value a5)
Evaluates a method with 5 args.
|
Value |
callMethodRef(Env env,
StringValue methodName)
Evaluates a method with 0 args.
|
Value |
callMethodRef(Env env,
StringValue methodName,
int hash)
Evaluates a method with 0 args.
|
Value |
callMethodRef(Env env,
StringValue methodName,
int hash,
Value a1)
Evaluates a method with 1 arg.
|
Value |
callMethodRef(Env env,
StringValue methodName,
int hash,
Value[] args)
Evaluates a method.
|
Value |
callMethodRef(Env env,
StringValue methodName,
int hash,
Value a1,
Value a2)
Evaluates a method with 2 args.
|
Value |
callMethodRef(Env env,
StringValue methodName,
int hash,
Value a1,
Value a2,
Value a3)
Evaluates a method with 3 args.
|
Value |
callMethodRef(Env env,
StringValue methodName,
int hash,
Value a1,
Value a2,
Value a3,
Value a4)
Evaluates a method with 4 args.
|
Value |
callMethodRef(Env env,
StringValue methodName,
int hash,
Value a1,
Value a2,
Value a3,
Value a4,
Value a5)
Evaluates a method with 5 args.
|
Value |
callMethodRef(Env env,
StringValue methodName,
Value a1)
Evaluates a method with 1 arg.
|
Value |
callMethodRef(Env env,
StringValue methodName,
Value[] args)
Evaluates a method.
|
Value |
callMethodRef(Env env,
StringValue methodName,
Value a1,
Value a2)
Evaluates a method with 2 args.
|
Value |
callMethodRef(Env env,
StringValue methodName,
Value a1,
Value a2,
Value a3)
Evaluates a method with 3 args.
|
Value |
callMethodRef(Env env,
StringValue methodName,
Value a1,
Value a2,
Value a3,
Value a4)
Evaluates a method with 4 args.
|
Value |
callMethodRef(Env env,
StringValue methodName,
Value a1,
Value a2,
Value a3,
Value a4,
Value a5)
Evaluates a method with 5 args.
|
Value |
callRef(Env env)
Evaluates the function.
|
Value |
callRef(Env env,
Value a1)
Evaluates the function with an argument .
|
Value |
callRef(Env env,
Value[] args)
Evaluates the function, returning a reference.
|
Value |
callRef(Env env,
Value a1,
Value a2)
Evaluates the function with arguments
|
Value |
callRef(Env env,
Value a1,
Value a2,
Value a3)
Evaluates the function with arguments
|
Value |
callRef(Env env,
Value a1,
Value a2,
Value a3,
Value a4)
Evaluates the function with arguments
|
Value |
callRef(Env env,
Value a1,
Value a2,
Value a3,
Value a4,
Value a5)
Evaluates the function with arguments
|
Value |
charValueAt(long index)
Returns the character at the named index.
|
void |
checkPrivate(Env env,
java.lang.String className)
Checks if 'this' is a valid private call for 'className'
|
void |
checkProtected(Env env,
java.lang.String className)
Checks if 'this' is a valid protected call for 'className'
|
Value |
clone(Env env)
Clone for the clone keyword
|
int |
cmp(Value rValue)
Returns a negative/positive integer if this Value is
lessthan/greaterthan rValue.
|
Value |
containsKey(Value key)
Returns the corresponding value if this array contains the given key
|
Value |
copy()
Copy for assignment.
|
Value |
copy(Env env)
Copy for serialization
|
Value |
copy(Env env,
java.util.IdentityHashMap<Value,Value> map)
Copy for serialization
|
Value |
copyArrayItem()
Copy as an array item
|
Value |
copyReturn()
Copy as a return value
|
Value |
copySaveFunArg()
Copy for saving a method's arguments.
|
StringValue |
copyStringBuilder()
Converts to a string builder
|
Value |
copyTree(Env env,
CopyRoot root)
Copy for serialization
|
Value |
current()
Returns the current value
|
Value |
div(long r)
Multiplies to the following value.
|
Value |
div(Value rValue)
Divides the following value.
|
Value |
end()
Returns the end value.
|
boolean |
eq(Value rValue)
Returns true for equality
|
boolean |
eql(Value rValue)
Returns true for equality
|
Value |
eqValue(Value rValue)
Returns true for equality
|
AbstractFunction |
findFunction(StringValue methodName)
Finds the method name.
|
QuercusClass |
findQuercusClass(Env env)
Returns the Quercus class for this obj/name.
|
void |
generate(java.io.PrintWriter out)
Generates code to recreate the expression.
|
boolean |
geq(Value rValue)
Returns true for greater than or equal to
|
Value |
get(long index)
Helper method that calls get(Value).
|
Value |
get(Value index)
Returns the array ref.
|
Value |
getArg(Value index,
boolean isTop)
Returns the array ref as a function argument.
|
Value |
getArgTail(Env env,
boolean isTop)
Sets the array tail, returning a reference to the tail.
|
Value |
getArray()
Returns the value for a field, creating an array if the field
is unset.
|
Value |
getArray(Value index)
Returns the value for a field, creating an array if the field
is unset.
|
java.util.Iterator<java.util.Map.Entry<Value,Value>> |
getBaseIterator(Env env)
Returns an iterator for the key => value pairs.
|
java.lang.String |
getCallableName()
Returns the callable's name for is_callable()
|
Value |
getCalledClass(Env env)
Returns the called class
|
java.lang.String |
getClassName()
Returns the value's class name.
|
int |
getCount(Env env)
Returns the count, as returned by the global php count() function
|
int |
getCountRecursive(Env env)
Returns the count, as returned by the global php count() function
|
Value |
getDirty(Value index)
Returns the array value, copying on write if necessary.
|
Value |
getField(Env env,
StringValue name)
Returns the field value
|
Value |
getFieldArg(Env env,
StringValue name,
boolean isTop)
Returns the field used as a method argument
|
Value |
getFieldArgRef(Env env,
StringValue name)
Returns the field ref for an argument.
|
Value |
getFieldArray(Env env,
StringValue name)
Returns the value for a field, creating an object if the field
is unset.
|
Value |
getFieldObject(Env env,
StringValue name)
Returns the value for a field, creating an object if the field
is unset.
|
Var |
getFieldVar(Env env,
StringValue name)
Returns the field ref.
|
int |
getHashCode() |
java.util.Iterator<java.util.Map.Entry<Value,Value>> |
getIterator(Env env)
Returns an iterator for the key => value pairs.
|
Value[] |
getKeyArray(Env env)
Returns the field keys.
|
java.util.Iterator<Value> |
getKeyIterator(Env env)
Returns an iterator for the field keys.
|
Value |
getObject(Env env)
Returns the value for the variable, creating an object if the var
is unset.
|
Value |
getObject(Env env,
Value index)
Returns the value for a field, creating an object if the field
is unset.
|
StringValue |
getObjectHash(Env env)
Returns the SPL object hash.
|
QuercusClass |
getQuercusClass()
Returns the backing QuercusClass.
|
Value |
getRef(Value index)
Returns a reference to the array value.
|
java.lang.String |
getResourceType()
Returns the resource type.
|
int |
getSize()
Returns the array size.
|
Value |
getStaticFieldValue(Env env,
StringValue name)
Returns the static field.
|
Var |
getStaticFieldVar(Env env,
StringValue name)
Returns the static field reference.
|
Value |
getThisField(Env env,
StringValue name)
Returns the field as a Var or Value.
|
Value |
getThisFieldArg(Env env,
StringValue name)
Returns the field used as a method argument
|
Value |
getThisFieldArgRef(Env env,
StringValue name)
Returns the field ref for an argument.
|
Value |
getThisFieldArray(Env env,
StringValue name)
Returns the value for a field, creating an object if the field
is unset.
|
Value |
getThisFieldObject(Env env,
StringValue name)
Returns the value for a field, creating an object if the field
is unset.
|
Var |
getThisFieldVar(Env env,
StringValue name)
Returns the field as a Var.
|
java.lang.String |
getType()
Returns the type.
|
Value[] |
getValueArray(Env env)
Returns the field values.
|
java.util.Iterator<Value> |
getValueIterator(Env env)
Returns an iterator for the field values.
|
ValueType |
getValueType()
Returns the ValueType.
|
Var |
getVar(Value index)
Returns a reference to the array value.
|
boolean |
gt(Value rValue)
Returns true for greater than
|
boolean |
hasCurrent()
Returns true if there are more elements.
|
int |
hashCode() |
Value |
increment(int incr)
Increment the following value.
|
void |
initField(Env env,
ClassField field,
boolean isInitFieldValues) |
void |
initField(Env env,
StringValue name,
StringValue canonicalName,
Value value) |
void |
initField(Env env,
StringValue canonicalName,
Value value) |
void |
initIncompleteField(Env env,
StringValue name,
Value value,
FieldVisibility visibility) |
boolean |
isA(Env env,
java.lang.String name)
Returns true for an implementation of a class
|
boolean |
isA(Env env,
Value value)
Returns true for an implementation of a class
|
boolean |
isArray()
Returns true for an array.
|
boolean |
isBinary()
Returns true for a BinaryValue.
|
boolean |
isBoolean()
Returns true for a BooleanValue
|
boolean |
isCallable(Env env,
boolean isCheckSyntaxOnly,
Value nameRef)
Returns true for a callable object.
|
boolean |
isDefault()
Returns true for a DefaultValue
|
boolean |
isDouble()
Returns true for a long-value.
|
boolean |
isDoubleConvertible()
Returns true for a double-value.
|
boolean |
isEmpty()
Returns true if the value is empty
|
boolean |
isEmpty(Env env,
Value index)
Returns true if the value is empty
|
boolean |
isFieldExists(Env env,
StringValue name)
Returns true if the object has this field.
|
boolean |
isFieldInit()
Returns true if the object is in a __set() method call.
|
boolean |
isLong()
Returns true for a long-value.
|
boolean |
isLongConvertible()
Returns true for a long-value.
|
boolean |
isNull()
Returns true for a null.
|
boolean |
isNumberConvertible()
Returns true for a number.
|
boolean |
isNumeric()
Matches is_numeric
|
boolean |
isObject()
Returns true for an object.
|
boolean |
isResource()
Returns true for a resource.
|
boolean |
isset()
Returns true if the value is set.
|
boolean |
isset(Value index)
Return true if the array value is set
|
boolean |
issetField(Env env,
StringValue name)
Returns true if the field is set
|
boolean |
issetThisField(Env env,
StringValue name)
Returns true if the field is set
|
boolean |
isString()
Returns true for a StringValue.
|
boolean |
isUnicode()
Returns true for a UnicodeValue.
|
boolean |
isVar() |
void |
jsonEncode(Env env,
JsonEncodeContext context,
StringValue sb)
Encodes the value in JSON.
|
Value |
key()
Returns the current key
|
boolean |
keyExists(Value key)
Returns true if the key exists in the array.
|
int |
length()
Returns the length as a string.
|
boolean |
leq(Value rValue)
Returns true for less than or equal to
|
Value |
lshift(Value rValue)
Shifts left by the value.
|
boolean |
lt(Value rValue)
Returns true for less than
|
Value |
mod(Value rValue)
modulo the following value.
|
Value |
mul(long r)
Multiplies to the following value.
|
Value |
mul(Value rValue)
Multiplies to the following value.
|
Value |
neg()
Negates the value.
|
Value |
next()
Returns the next value
|
long |
nextIndex(long oldIndex)
Returns the next array index based on this value.
|
Value |
pop(Env env)
Pops the top array element.
|
Value |
pos()
Negates the value.
|
Value |
postdecr()
Post-increment the following value.
|
Value |
postincr()
Post-increment the following value.
|
Value |
postincr(int incr)
Post-increment the following value.
|
Value |
predecr()
Pre-increment the following value.
|
Value |
preincr()
Pre-increment the following value.
|
Value |
preincr(int incr)
Pre-increment the following value.
|
Value |
prev()
Returns the previous value
|
void |
print(Env env)
Prints the value.
|
void |
print(Env env,
WriteStream out)
Prints the value.
|
protected void |
printDepth(WriteStream out,
int depth) |
protected static void |
printJavaChar(java.io.PrintWriter out,
char ch) |
protected static void |
printJavaString(java.io.PrintWriter out,
StringValue s) |
void |
printR(Env env,
WriteStream out,
int depth,
java.util.IdentityHashMap<Value,java.lang.String> valueSet) |
protected void |
printRImpl(Env env,
WriteStream out,
int depth,
java.util.IdentityHashMap<Value,java.lang.String> valueSet) |
Value |
put(Value value)
Appends an array value
|
Value |
put(Value index,
Value value)
Sets the array ref and returns the value
|
Value |
put(Value index,
Value value,
Value innerIndex,
Value innerValue)
Sets the array ref.
|
Value |
putArray(Env env)
Appends a new array.
|
Value |
putField(Env env,
java.lang.String name,
Value value) |
Value |
putField(Env env,
StringValue name,
Value object)
Returns the field ref.
|
Value |
putField(Env env,
StringValue name,
Value value,
Value innerIndex,
Value innerValue) |
Value |
putObject(Env env)
Appends a new object
|
Value |
putThisField(Env env,
StringValue name,
Value object)
Returns the field ref.
|
Value |
putThisField(Env env,
StringValue name,
Value array,
Value index,
Value value)
Sets an array field ref.
|
Value |
putThisFieldArray(Env env,
Value obj,
StringValue fieldName,
Value index,
Value value)
Appends a value to an array that is a field of an object.
|
Var |
putVar()
Sets the array tail, returning the Var of the tail.
|
Value |
remove(Value index)
Return unset the value.
|
Value |
reset()
Returns the array pointer.
|
Value |
rshift(Value rValue)
Shifts right by the value.
|
void |
serialize(Env env,
java.lang.StringBuilder sb)
Serializes the value.
|
void |
serialize(Env env,
java.lang.StringBuilder sb,
SerializeMap serializeMap)
Serializes the value.
|
Value |
set(Value value)
Sets the value ref.
|
Value |
setCharValueAt(long index,
Value value)
Sets the character at the named index.
|
void |
setFieldInit(boolean isInit) |
void |
setJavaObject(java.lang.Object obj)
Binds a Java object to this object.
|
Value |
setStaticFieldRef(Env env,
StringValue name,
Value value)
Sets the static field.
|
Value |
shuffle()
Shuffles the array.
|
Value |
sub_rev(long lLong)
Substracts from the previous value.
|
Value |
sub(long rLong)
Subtracts
|
Value |
sub(Value rValue)
Subtracts to the following value.
|
Value |
subOne()
Return the previous integer
|
Value |
toArgRef()
Convert to a function argument reference value, e.g.
|
ArrayValue |
toArray()
Converts to an array.
|
ArrayValue |
toArrayValue(Env env)
Casts to an array.
|
Value |
toAutoArray()
Converts to an array if null.
|
Value |
toAutoObject(Env env)
Converts to an object if null.
|
java.math.BigDecimal |
toBigDecimal()
Converts to a Java BigDecimal.
|
java.math.BigInteger |
toBigInteger()
Converts to a Java BigInteger.
|
StringValue |
toBinaryValue()
Converts to a BinaryValue.
|
StringValue |
toBinaryValue(Env env)
Converts to a BinaryValue.
|
StringValue |
toBinaryValue(java.lang.String charset)
Converts to a BinaryValue.
|
int |
toBinaryValueMarshalCost()
Cost to convert to a binary value
|
boolean |
toBoolean()
Converts to a boolean.
|
int |
toBooleanMarshalCost()
Cost to convert to a boolean
|
int |
toByteArrayMarshalCost()
Cost to convert to a byte[]
|
int |
toByteMarshalCost()
Cost to convert to a byte
|
Callable |
toCallable(Env env,
boolean isOptional)
Converts to a callable
|
char |
toChar()
Converts to a char
|
int |
toCharArrayMarshalCost()
Cost to convert to a char[]
|
int |
toCharMarshalCost()
Cost to convert to a character
|
java.lang.String |
toDebugString() |
double |
toDouble()
Converts to a double.
|
static double |
toDouble(boolean b) |
static double |
toDouble(java.lang.CharSequence s) |
static double |
toDouble(double d) |
static double |
toDouble(long l) |
int |
toDoubleMarshalCost()
Cost to convert to a double
|
DoubleValue |
toDoubleValue()
Converts to a double vaule
|
QuercusException |
toException(Env env,
java.lang.String file,
int line)
Converts to an exception.
|
int |
toFloatMarshalCost()
Cost to convert to a float
|
java.io.InputStream |
toInputStream()
Returns a byteArrayInputStream for the value.
|
int |
toInt()
Converts to an int
|
int |
toIntegerMarshalCost()
Cost to convert to an integer
|
java.lang.String |
toInternString() |
java.lang.Boolean |
toJavaBoolean()
Converts to a java boolean object.
|
java.lang.Byte |
toJavaByte()
Converts to a java byte object.
|
java.util.Calendar |
toJavaCalendar()
Converts to a Java Calendar.
|
java.lang.Character |
toJavaCharacter()
Converts to a java Character object.
|
java.util.Collection<?> |
toJavaCollection(Env env,
java.lang.Class<?> type)
Converts to a java Collection object.
|
java.util.Date |
toJavaDate()
Converts to a Java Date.
|
java.lang.Double |
toJavaDouble()
Converts to a java Double object.
|
java.lang.Enum |
toJavaEnum(Env env,
java.lang.Class cls)
Converts to a Java Enum.
|
java.lang.Float |
toJavaFloat()
Converts to a java Float object.
|
java.lang.Integer |
toJavaInteger()
Converts to a java Integer object.
|
java.util.List<?> |
toJavaList(Env env,
java.lang.Class<?> type)
Converts to a java List object.
|
java.lang.Long |
toJavaLong()
Converts to a java Long object.
|
java.util.Map<?,?> |
toJavaMap(Env env,
java.lang.Class<?> type)
Converts to a java Map object.
|
java.lang.Object |
toJavaObject()
Converts to a java object.
|
java.lang.Object |
toJavaObject(Env env,
java.lang.Class<?> type)
Converts to a java object.
|
int |
toJavaObjectMarshalCost()
Cost to convert to a Java object
|
java.lang.Object |
toJavaObjectNotNull(Env env,
java.lang.Class<?> type)
Converts to a java object.
|
java.lang.Short |
toJavaShort()
Converts to a java short object.
|
java.lang.String |
toJavaString()
Converts to a java String object.
|
java.net.URL |
toJavaURL(Env env)
Converts to a Java URL.
|
Value |
toKey()
Converts to a key.
|
Value |
toLocalRef()
Convert to a function argument value, e.g.
|
Value |
toLocalThis(QuercusClass qClass)
Converts to a local $this, which can depend on the calling class
|
Value |
toLocalValue()
Convert to a function argument value, e.g.
|
Value |
toLocalValueReadOnly()
Convert to a function argument value, e.g.
|
Var |
toLocalVar()
Convert to a function argument value, e.g.
|
Var |
toLocalVarDeclAsRef()
Convert to a function argument reference value, e.g.
|
long |
toLong()
Converts to a long.
|
static long |
toLong(boolean b) |
static long |
toLong(java.lang.CharSequence s) |
static long |
toLong(double d) |
static long |
toLong(long l) |
int |
toLongMarshalCost()
Cost to convert to a long
|
LongValue |
toLongValue()
Converts to a long vaule
|
Value |
toObject(Env env)
Converts to an object.
|
Value |
toRef()
Convert to a ref.
|
Value |
toRefValue()
Convert to a function argument reference value, e.g.
|
int |
toShortMarshalCost()
Cost to convert to a short
|
StringValue |
toString(Env env)
Converts to a string.
|
StringValue |
toStringBuilder()
Converts to a string builder
|
StringValue |
toStringBuilder(Env env)
Converts to a string builder
|
StringValue |
toStringBuilder(Env env,
StringValue value)
Converts to a string builder
|
StringValue |
toStringBuilder(Env env,
Value value)
Converts to a string builder
|
int |
toStringMarshalCost()
Cost to convert to a string
|
StringValue |
toStringValue()
Converts to a StringValue.
|
StringValue |
toStringValue(Env env)
Converts to a StringValue.
|
int |
toStringValueMarshalCost()
Cost to convert to a StringValue
|
StringValue |
toUnicode(Env env)
Converts to a Unicode string.
|
StringValue |
toUnicodeValue()
Converts to a UnicodeValue for marshaling, so it will create a
UnicodeValue event when unicode.semantics=false.
|
StringValue |
toUnicodeValue(Env env)
Converts to a UnicodeValue for marshaling, so it will create a
UnicodeValue event when unicode.semantics=false.
|
int |
toUnicodeValueMarshalCost()
Cost to convert to a UnicodeValue
|
Value |
toValue()
Converts to a raw value.
|
Var |
toVar()
Converts to a Var.
|
void |
unsetArray(Env env,
StringValue name,
Value index)
Removes the field ref.
|
void |
unsetField(StringValue name)
Removes the field ref.
|
void |
unsetThisArray(Env env,
StringValue name,
Value index)
Removes the field ref.
|
void |
unsetThisField(StringValue name)
Removes the field ref.
|
void |
unsetThisPrivateField(java.lang.String className,
StringValue name)
Removes the field ref.
|
java.lang.Object |
valuesToArray(Env env,
java.lang.Class<?> elementType)
Takes the values of this array, unmarshalls them to objects of type
elementType, and puts them in a java array.
|
void |
varDump(Env env,
WriteStream out,
int depth,
java.util.IdentityHashMap<Value,java.lang.String> valueSet) |
protected void |
varDumpImpl(Env env,
WriteStream out,
int depth,
java.util.IdentityHashMap<Value,java.lang.String> valueSet) |
StringValue |
varExport(Env env)
Exports the value.
|
protected void |
varExportImpl(StringValue sb,
int level)
Exports the value.
|
protected static final L10N L
public static final Value[] NULL_VALUE_ARRAY
public static final Value[] NULL_ARGS
public java.lang.String getClassName()
public QuercusClass getQuercusClass()
public QuercusClass findQuercusClass(Env env)
public boolean isA(Env env, java.lang.String name)
public void checkProtected(Env env, java.lang.String className)
public void checkPrivate(Env env, java.lang.String className)
public ValueType getValueType()
public boolean isArray()
public boolean isDoubleConvertible()
public boolean isLongConvertible()
public boolean isLong()
public boolean isDouble()
public boolean isNull()
public boolean isNumberConvertible()
public boolean isNumeric()
public boolean isObject()
public boolean isResource()
public boolean isString()
public boolean isBinary()
public boolean isUnicode()
public boolean isBoolean()
public boolean isDefault()
public int toBooleanMarshalCost()
public int toByteMarshalCost()
public int toShortMarshalCost()
public int toIntegerMarshalCost()
public int toLongMarshalCost()
public int toDoubleMarshalCost()
public int toFloatMarshalCost()
public int toCharMarshalCost()
public int toStringMarshalCost()
public int toByteArrayMarshalCost()
public int toCharArrayMarshalCost()
public int toJavaObjectMarshalCost()
public int toBinaryValueMarshalCost()
public int toStringValueMarshalCost()
public int toUnicodeValueMarshalCost()
public boolean isset()
public boolean isEmpty()
public boolean hasCurrent()
public boolean eq(Value rValue)
public boolean eql(Value rValue)
public int cmp(Value rValue)
public boolean lt(Value rValue)
public boolean leq(Value rValue)
public boolean gt(Value rValue)
public boolean geq(Value rValue)
public static long toLong(boolean b)
public static long toLong(double d)
public static long toLong(long l)
public static long toLong(java.lang.CharSequence s)
public static double toDouble(boolean b)
public static double toDouble(double d)
public static double toDouble(long l)
public static double toDouble(java.lang.CharSequence s)
public boolean toBoolean()
public long toLong()
public int toInt()
public double toDouble()
public char toChar()
public StringValue toString(Env env)
env
- public ArrayValue toArray()
public Value toAutoArray()
public ArrayValue toArrayValue(Env env)
public java.lang.Object toJavaObject()
public java.lang.Object toJavaObject(Env env, java.lang.Class<?> type)
public java.lang.Object toJavaObjectNotNull(Env env, java.lang.Class<?> type)
public java.lang.Boolean toJavaBoolean()
public java.lang.Byte toJavaByte()
public java.lang.Short toJavaShort()
public java.lang.Integer toJavaInteger()
public java.lang.Long toJavaLong()
public java.lang.Float toJavaFloat()
public java.lang.Double toJavaDouble()
public java.lang.Character toJavaCharacter()
public java.lang.String toJavaString()
public java.util.Collection<?> toJavaCollection(Env env, java.lang.Class<?> type)
public java.util.List<?> toJavaList(Env env, java.lang.Class<?> type)
public java.util.Map<?,?> toJavaMap(Env env, java.lang.Class<?> type)
public java.util.Calendar toJavaCalendar()
public java.util.Date toJavaDate()
public java.net.URL toJavaURL(Env env)
public java.lang.Enum toJavaEnum(Env env, java.lang.Class cls)
public java.math.BigDecimal toBigDecimal()
public java.math.BigInteger toBigInteger()
public QuercusException toException(Env env, java.lang.String file, int line)
public Value toValue()
public Value toKey()
public Value toRef()
public Value toLocalValueReadOnly()
public Value toLocalValue()
public Value toLocalRef()
public Var toLocalVar()
public Var toLocalVarDeclAsRef()
public Value toLocalThis(QuercusClass qClass)
public Value toRefValue()
public Var toVar()
public Value toArgRef()
public StringValue toStringValue()
public StringValue toStringValue(Env env)
public StringValue toUnicode(Env env)
public StringValue toUnicodeValue()
public StringValue toUnicodeValue(Env env)
public StringValue toBinaryValue()
public StringValue toBinaryValue(java.lang.String charset)
public StringValue toBinaryValue(Env env)
public java.io.InputStream toInputStream()
public StringValue toStringBuilder()
public StringValue toStringBuilder(Env env)
public StringValue toStringBuilder(Env env, Value value)
public StringValue toStringBuilder(Env env, StringValue value)
public StringValue copyStringBuilder()
public LongValue toLongValue()
public DoubleValue toDoubleValue()
public boolean isCallable(Env env, boolean isCheckSyntaxOnly, Value nameRef)
public java.lang.String getCallableName()
public StringValue appendTo(UnicodeBuilderValue sb)
public StringValue appendTo(StringBuilderValue sb)
public StringValue appendTo(BinaryBuilderValue sb)
public StringValue appendTo(LargeStringBuilderValue sb)
public Value copy()
public Value copyArrayItem()
public Value copyReturn()
public Value copySaveFunArg()
public java.lang.String getType()
public StringValue getObjectHash(Env env)
public java.lang.String getResourceType()
public Value key()
public Value current()
public Value next()
public Value prev()
public Value end()
public Value reset()
public Value shuffle()
public AbstractFunction findFunction(StringValue methodName)
public Value callRef(Env env, Value a1, Value a2, Value a3)
public Value call(Env env, Value a1, Value a2, Value a3, Value a4)
public Value callRef(Env env, Value a1, Value a2, Value a3, Value a4)
public Value call(Env env, Value a1, Value a2, Value a3, Value a4, Value a5)
public Value callRef(Env env, Value a1, Value a2, Value a3, Value a4, Value a5)
public Value callMethod(Env env, StringValue methodName, int hash, Value[] args)
public final Value callMethod(Env env, StringValue methodName, Value[] args)
public Value callMethodRef(Env env, StringValue methodName, int hash, Value[] args)
public final Value callMethodRef(Env env, StringValue methodName, Value[] args)
public Value callMethod(Env env, StringValue methodName, int hash)
public final Value callMethod(Env env, StringValue methodName)
public Value callMethodRef(Env env, StringValue methodName, int hash)
public final Value callMethodRef(Env env, StringValue methodName)
public Value callMethod(Env env, StringValue methodName, int hash, Value a1)
public final Value callMethod(Env env, StringValue methodName, Value a1)
public Value callMethodRef(Env env, StringValue methodName, int hash, Value a1)
public final Value callMethodRef(Env env, StringValue methodName, Value a1)
public Value callMethod(Env env, StringValue methodName, int hash, Value a1, Value a2)
public final Value callMethod(Env env, StringValue methodName, Value a1, Value a2)
public Value callMethodRef(Env env, StringValue methodName, int hash, Value a1, Value a2)
public final Value callMethodRef(Env env, StringValue methodName, Value a1, Value a2)
public Value callMethod(Env env, StringValue methodName, int hash, Value a1, Value a2, Value a3)
public final Value callMethod(Env env, StringValue methodName, Value a1, Value a2, Value a3)
public Value callMethodRef(Env env, StringValue methodName, int hash, Value a1, Value a2, Value a3)
public final Value callMethodRef(Env env, StringValue methodName, Value a1, Value a2, Value a3)
public Value callMethod(Env env, StringValue methodName, int hash, Value a1, Value a2, Value a3, Value a4)
public final Value callMethod(Env env, StringValue methodName, Value a1, Value a2, Value a3, Value a4)
public Value callMethodRef(Env env, StringValue methodName, int hash, Value a1, Value a2, Value a3, Value a4)
public final Value callMethodRef(Env env, StringValue methodName, Value a1, Value a2, Value a3, Value a4)
public Value callMethod(Env env, StringValue methodName, int hash, Value a1, Value a2, Value a3, Value a4, Value a5)
public final Value callMethod(Env env, StringValue methodName, Value a1, Value a2, Value a3, Value a4, Value a5)
public Value callMethodRef(Env env, StringValue methodName, int hash, Value a1, Value a2, Value a3, Value a4, Value a5)
public final Value callMethodRef(Env env, StringValue methodName, Value a1, Value a2, Value a3, Value a4, Value a5)
public Value neg()
public Value pos()
public Value add(long lLong)
public Value preincr(int incr)
public Value postincr(int incr)
public Value addOne()
public Value subOne()
public Value preincr()
public Value postincr()
public Value predecr()
public Value postdecr()
public Value increment(int incr)
public Value sub(long rLong)
public Value sub_rev(long lLong)
public Value mul(long r)
public Value div(long r)
public Value abs()
public long nextIndex(long oldIndex)
public int length()
public int getSize()
public int getCount(Env env)
public int getCountRecursive(Env env)
public java.util.Iterator<java.util.Map.Entry<Value,Value>> getIterator(Env env)
public java.util.Iterator<java.util.Map.Entry<Value,Value>> getBaseIterator(Env env)
public java.util.Iterator<Value> getKeyIterator(Env env)
getIterator(Env)
; derived classes may override and
provide a more efficient implementation.public java.util.Iterator<Value> getValueIterator(Env env)
getIterator(Env)
; derived classes may override and
provide a more efficient implementation.public Value getField(Env env, StringValue name)
public Var getFieldVar(Env env, StringValue name)
public Value getFieldArg(Env env, StringValue name, boolean isTop)
public Value getFieldArgRef(Env env, StringValue name)
public Value getFieldObject(Env env, StringValue name)
public Value getFieldArray(Env env, StringValue name)
public Value putField(Env env, StringValue name, Value object)
public final Value putField(Env env, StringValue name, Value value, Value innerIndex, Value innerValue)
public void setFieldInit(boolean isInit)
public boolean isFieldInit()
public boolean isFieldExists(Env env, StringValue name)
public boolean issetField(Env env, StringValue name)
public void unsetField(StringValue name)
public void unsetArray(Env env, StringValue name, Value index)
public void unsetThisArray(Env env, StringValue name, Value index)
public Value putThisFieldArray(Env env, Value obj, StringValue fieldName, Value index, Value value)
public Value getThisField(Env env, StringValue name)
public Var getThisFieldVar(Env env, StringValue name)
public Value getThisFieldArg(Env env, StringValue name)
public Value getThisFieldArgRef(Env env, StringValue name)
public Value getThisFieldObject(Env env, StringValue name)
public Value getThisFieldArray(Env env, StringValue name)
public final void initField(Env env, ClassField field, boolean isInitFieldValues)
public final void initField(Env env, StringValue canonicalName, Value value)
public void initField(Env env, StringValue name, StringValue canonicalName, Value value)
public void initIncompleteField(Env env, StringValue name, Value value, FieldVisibility visibility)
public Value putThisField(Env env, StringValue name, Value object)
public Value putThisField(Env env, StringValue name, Value array, Value index, Value value)
public boolean issetThisField(Env env, StringValue name)
public void unsetThisField(StringValue name)
public void unsetThisPrivateField(java.lang.String className, StringValue name)
public Value getStaticFieldValue(Env env, StringValue name)
public Var getStaticFieldVar(Env env, StringValue name)
public Value setStaticFieldRef(Env env, StringValue name, Value value)
public final Value get(long index)
public Value getArg(Value index, boolean isTop)
public Value getArray()
public Value getArray(Value index)
public Value getObject(Env env)
public Value getObject(Env env, Value index)
public boolean isVar()
public final Value put(Value index, Value value, Value innerIndex, Value innerValue)
public Value append(Value index, Value value)
public Var putVar()
public Value getArgTail(Env env, boolean isTop)
public boolean isset(Value index)
public boolean keyExists(Value key)
public Value containsKey(Value key)
key
- to search for in the arraypublic java.lang.Object valuesToArray(Env env, java.lang.Class<?> elementType)
public Value charValueAt(long index)
public Value setCharValueAt(long index, Value value)
public void print(Env env)
env
- public void print(Env env, WriteStream out)
env
- public void serialize(Env env, java.lang.StringBuilder sb, SerializeMap serializeMap)
env
- sb
- holds result of serializationserializeMap
- holds reference indexespublic void jsonEncode(Env env, JsonEncodeContext context, StringValue sb)
public void serialize(Env env, java.lang.StringBuilder sb)
public StringValue varExport(Env env)
protected void varExportImpl(StringValue sb, int level)
public void setJavaObject(java.lang.Object obj)
public void generate(java.io.PrintWriter out) throws java.io.IOException
out
- the writer to the Java source code.java.io.IOException
protected static void printJavaChar(java.io.PrintWriter out, char ch)
protected static void printJavaString(java.io.PrintWriter out, StringValue s)
public java.lang.String toInternString()
public java.lang.String toDebugString()
public final void varDump(Env env, WriteStream out, int depth, java.util.IdentityHashMap<Value,java.lang.String> valueSet) throws java.io.IOException
java.io.IOException
protected void varDumpImpl(Env env, WriteStream out, int depth, java.util.IdentityHashMap<Value,java.lang.String> valueSet) throws java.io.IOException
java.io.IOException
public final void printR(Env env, WriteStream out, int depth, java.util.IdentityHashMap<Value,java.lang.String> valueSet) throws java.io.IOException
java.io.IOException
protected void printRImpl(Env env, WriteStream out, int depth, java.util.IdentityHashMap<Value,java.lang.String> valueSet) throws java.io.IOException
java.io.IOException
protected void printDepth(WriteStream out, int depth) throws java.io.IOException
java.io.IOException
public int getHashCode()
public int hashCode()
hashCode
in class java.lang.Object