public class NativeRegExp extends IdScriptableObject
Revision History: Implementation in C by Brendan Eich Initial port to Java by Norris Boyd from jsregexp.c version 1.36 Merged up to version 1.38, which included Unicode support. Merged bug fixes in version 1.39. Merged JSFUN13_BRANCH changes up to 1.32.2.13
ScriptableObject.KeyComparator
Modifier and Type | Field and Description |
---|---|
static int |
JSREG_FOLD |
static int |
JSREG_GLOB |
static int |
JSREG_MULTILINE |
static int |
MATCH |
static int |
PREFIX |
static int |
TEST |
CONST, DONTENUM, EMPTY, PERMANENT, READONLY, UNINITIALIZED_CONST
NOT_FOUND
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
execIdCall(IdFunctionObject f,
Context cx,
Scriptable scope,
Scriptable thisObj,
java.lang.Object[] args)
'thisObj' will be null if invoked as constructor, in which case * instance of Scriptable
should be returned.
|
protected int |
findInstanceIdInfo(java.lang.String s)
Map name to id of instance property.
|
protected int |
findPrototypeId(java.lang.String s) |
protected int |
findPrototypeId(Symbol k) |
java.lang.String |
getClassName()
Return the name of the class.
|
protected java.lang.String |
getInstanceIdName(int id)
Map id back to property name it defines.
|
protected java.lang.Object |
getInstanceIdValue(int id)
Get id value.
|
protected int |
getMaxInstanceId()
Get maximum id findInstanceIdInfo can generate.
|
java.lang.String |
getTypeOf()
Gets the value to be returned by the typeof operator called on this object.
|
static void |
init(Context cx,
Scriptable scope,
boolean sealed) |
protected void |
initPrototypeId(int id) |
protected void |
setInstanceIdAttributes(int id,
int attr)
Update the attributes of the given instance property.
|
protected void |
setInstanceIdValue(int id,
java.lang.Object value)
Set or delete id value.
|
java.lang.String |
toString() |
activatePrototypeMap, addIdFunctionProperty, defaultGet, defaultHas, defaultPut, defineOwnProperty, delete, delete, ensureType, exportAsJSClass, fillConstructorProperties, findInstanceIdInfo, get, get, getAttributes, getAttributes, getOwnPropertyDescriptor, has, has, hasPrototypeMap, initPrototypeConstructor, initPrototypeMethod, initPrototypeMethod, initPrototypeMethod, initPrototypeValue, initPrototypeValue, instanceIdInfo, put, put, setAttributes
applyDescriptorToAttributeBitset, associateValue, avoidObjectDetection, buildDataDescriptor, callMethod, callMethod, checkPropertyChange, checkPropertyDefinition, defineClass, defineClass, defineClass, defineConst, defineConstProperty, defineFunctionProperties, defineOwnProperties, defineOwnProperty, defineProperty, defineProperty, defineProperty, defineProperty, defineProperty, defineProperty, delete, deleteProperty, deleteProperty, ensureScriptable, ensureScriptableObject, ensureSymbolScriptable, equivalentValues, get, get, getAllIds, getArrayPrototype, getAssociatedValue, getAttributes, getAttributes, getAttributes, getClassPrototype, getDefaultValue, getDefaultValue, getExternalArrayData, getExternalArrayLength, getFunctionPrototype, getGeneratorFunctionPrototype, getGetterOrSetter, getGetterOrSetter, getIds, getObjectPrototype, getParentScope, getProperty, getProperty, getProperty, getPropertyIds, getPrototype, getTopLevelScope, getTopScopeValue, getTypedProperty, getTypedProperty, has, hasInstance, hasProperty, hasProperty, hasProperty, isAccessorDescriptor, isConst, isDataDescriptor, isEmpty, isExtensible, isFalse, isGenericDescriptor, isGetterOrSetter, isSealed, isTrue, preventExtensions, put, putConst, putConstProperty, putProperty, putProperty, putProperty, querySlot, redefineProperty, sameValue, sealObject, setAttributes, setAttributes, setAttributes, setAttributes, setCommonDescriptorProperties, setExternalArrayData, setGetterOrSetter, setParentScope, setPrototype, size
public static final int JSREG_GLOB
public static final int JSREG_FOLD
public static final int JSREG_MULTILINE
public static final int TEST
public static final int MATCH
public static final int PREFIX
public static void init(Context cx, Scriptable scope, boolean sealed)
public java.lang.String getClassName()
ScriptableObject
This is typically the same name as the constructor. Classes extending ScriptableObject must implement this abstract method.
getClassName
in interface Scriptable
getClassName
in class ScriptableObject
public java.lang.String getTypeOf()
getTypeOf
in class ScriptableObject
ScriptableObject.getTypeOf()
public java.lang.String toString()
toString
in class java.lang.Object
protected int getMaxInstanceId()
IdScriptableObject
getMaxInstanceId
in class IdScriptableObject
protected int findInstanceIdInfo(java.lang.String s)
IdScriptableObject
IdScriptableObject.instanceIdInfo(int, int)
.findInstanceIdInfo
in class IdScriptableObject
protected java.lang.String getInstanceIdName(int id)
IdScriptableObject
getInstanceIdName
in class IdScriptableObject
protected java.lang.Object getInstanceIdValue(int id)
IdScriptableObject
getInstanceIdValue
in class IdScriptableObject
protected void setInstanceIdValue(int id, java.lang.Object value)
IdScriptableObject
setInstanceIdValue
in class IdScriptableObject
protected void setInstanceIdAttributes(int id, int attr)
IdScriptableObject
setInstanceIdAttributes
in class IdScriptableObject
id
- the instance property idattr
- the new attribute bitsetprotected void initPrototypeId(int id)
initPrototypeId
in class IdScriptableObject
public java.lang.Object execIdCall(IdFunctionObject f, Context cx, Scriptable scope, Scriptable thisObj, java.lang.Object[] args)
IdScriptableObject
execIdCall
in interface IdFunctionCall
execIdCall
in class IdScriptableObject
protected int findPrototypeId(Symbol k)
findPrototypeId
in class IdScriptableObject
protected int findPrototypeId(java.lang.String s)
findPrototypeId
in class IdScriptableObject