Class ScriptableProperty
- java.lang.Object
-
- org.mozilla.javascript.ScriptableObject
-
- org.apache.sling.scripting.javascript.wrapper.ScriptableBase
-
- org.apache.sling.scripting.javascript.wrapper.ScriptableProperty
-
- All Implemented Interfaces:
java.io.Serializable,SlingWrapper,org.mozilla.javascript.ConstProperties,org.mozilla.javascript.debug.DebuggableObject,org.mozilla.javascript.Scriptable,org.mozilla.javascript.Wrapper
public class ScriptableProperty extends ScriptableBase implements SlingWrapper
Wrap a JCR Property as a Scriptable- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringCLASSNAME-
Fields inherited from class org.apache.sling.scripting.javascript.wrapper.ScriptableBase
JSFUNC_PREFIX
-
-
Constructor Summary
Constructors Constructor Description ScriptableProperty()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Objectget(java.lang.String name, org.mozilla.javascript.Scriptable start)java.lang.StringgetClassName()The name of the JavaScript host object "class".protected java.lang.Class<?>getStaticType()intgetType()java.lang.Class<?>[]getWrappedClasses()The list of Java classes wrapped by this wrapper.protected java.lang.ObjectgetWrappedObject()voidjsConstructor(java.lang.Object res)java.lang.ObjectjsFunction_toString()java.lang.ObjectjsFunction_valueOf(java.lang.String hint)java.lang.ObjectjsGet_boolean()java.lang.ObjectjsGet_date()java.lang.ObjectjsGet_definition()intjsGet_depth()java.lang.ObjectjsGet_double()java.lang.ObjectjsGet_length()long[]jsGet_lengths()java.lang.ObjectjsGet_long()booleanjsGet_modified()java.lang.StringjsGet_name()booleanjsGet_new()java.lang.ObjectjsGet_node()java.lang.ObjectjsGet_parent()java.lang.StringjsGet_path()java.lang.ObjectjsGet_session()java.lang.ObjectjsGet_stream()java.lang.ObjectjsGet_string()java.lang.ObjectjsGet_value()java.lang.ObjectjsGet_values()java.lang.StringtoString()java.lang.Objectunwrap()-
Methods inherited from class org.apache.sling.scripting.javascript.wrapper.ScriptableBase
getNative
-
Methods inherited from class org.mozilla.javascript.ScriptableObject
applyDescriptorToAttributeBitset, associateValue, avoidObjectDetection, buildDataDescriptor, callMethod, callMethod, checkPropertyChange, checkPropertyDefinition, defineClass, defineClass, defineClass, defineConst, defineConstProperty, defineFunctionProperties, defineOwnProperties, defineOwnProperty, defineOwnProperty, defineProperty, defineProperty, defineProperty, defineProperty, delete, delete, deleteProperty, deleteProperty, ensureScriptable, ensureScriptableObject, equivalentValues, get, get, getAllIds, getArrayPrototype, getAssociatedValue, getAttributes, getAttributes, getAttributes, getAttributes, getClassPrototype, getDefaultValue, getDefaultValue, getExternalArrayData, getExternalArrayLength, getFunctionPrototype, getGetterOrSetter, getIds, getObjectPrototype, getOwnPropertyDescriptor, getParentScope, getProperty, getProperty, getPropertyIds, getPrototype, getSlot, getTopLevelScope, getTopScopeValue, getTypedProperty, getTypedProperty, getTypeOf, has, has, hasInstance, hasProperty, hasProperty, isAccessorDescriptor, isConst, isDataDescriptor, isEmpty, isExtensible, isFalse, isGenericDescriptor, isGetterOrSetter, isSealed, isTrue, preventExtensions, put, put, putConst, putConstProperty, putProperty, putProperty, redefineProperty, sameValue, sealObject, setAttributes, setAttributes, setAttributes, setAttributes, setExternalArrayData, setGetterOrSetter, setParentScope, setPrototype, size
-
-
-
-
Field Detail
-
CLASSNAME
public static final java.lang.String CLASSNAME
- See Also:
- Constant Field Values
-
-
Method Detail
-
jsConstructor
public void jsConstructor(java.lang.Object res)
-
getClassName
public java.lang.String getClassName()
Description copied from interface:SlingWrapperThe name of the JavaScript host object "class".- Specified by:
getClassNamein interfaceorg.mozilla.javascript.Scriptable- Specified by:
getClassNamein interfaceSlingWrapper- Specified by:
getClassNamein classorg.mozilla.javascript.ScriptableObject- Returns:
- the class name
-
getWrappedClasses
public java.lang.Class<?>[] getWrappedClasses()
Description copied from interface:SlingWrapperThe list of Java classes wrapped by this wrapper.- Specified by:
getWrappedClassesin interfaceSlingWrapper- Returns:
- the wrapped classes
-
jsGet_value
public java.lang.Object jsGet_value()
-
jsGet_values
public java.lang.Object jsGet_values()
-
jsGet_string
public java.lang.Object jsGet_string()
-
jsGet_stream
public java.lang.Object jsGet_stream()
-
jsGet_long
public java.lang.Object jsGet_long()
-
jsGet_double
public java.lang.Object jsGet_double()
-
jsGet_date
public java.lang.Object jsGet_date()
-
jsGet_boolean
public java.lang.Object jsGet_boolean()
-
jsGet_node
public java.lang.Object jsGet_node()
-
jsGet_length
public java.lang.Object jsGet_length()
-
jsGet_lengths
public long[] jsGet_lengths()
-
jsGet_definition
public java.lang.Object jsGet_definition()
-
getType
public int getType()
-
jsGet_session
public java.lang.Object jsGet_session()
-
jsGet_path
public java.lang.String jsGet_path()
-
jsGet_name
public java.lang.String jsGet_name()
-
jsGet_parent
public java.lang.Object jsGet_parent()
-
jsGet_depth
public int jsGet_depth()
-
jsGet_new
public boolean jsGet_new()
-
jsGet_modified
public boolean jsGet_modified()
-
jsFunction_valueOf
public java.lang.Object jsFunction_valueOf(java.lang.String hint)
-
get
public java.lang.Object get(java.lang.String name, org.mozilla.javascript.Scriptable start)- Specified by:
getin interfaceorg.mozilla.javascript.Scriptable- Overrides:
getin classorg.mozilla.javascript.ScriptableObject
-
jsFunction_toString
public java.lang.Object jsFunction_toString()
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
unwrap
public java.lang.Object unwrap()
- Specified by:
unwrapin interfaceorg.mozilla.javascript.Wrapper
-
getStaticType
protected java.lang.Class<?> getStaticType()
- Specified by:
getStaticTypein classScriptableBase- Returns:
- the static type to use for NativeJavaObject wrapping
-
getWrappedObject
protected java.lang.Object getWrappedObject()
- Specified by:
getWrappedObjectin classScriptableBase- Returns:
- the Java object that we're wrapping, used to create a NativeJavaObject instance for default wrapping.
-
-