Class HybridObject
java.lang.Object
org.apache.sling.scripting.sightly.js.impl.rhino.HybridObject
- All Implemented Interfaces:
org.apache.sling.scripting.sightly.Record<Object>
,org.mozilla.javascript.Scriptable
public class HybridObject
extends Object
implements org.mozilla.javascript.Scriptable, org.apache.sling.scripting.sightly.Record<Object>
Instances of this class can be used in both HTL & JavaScript scripts.
-
Field Summary
Fields inherited from interface org.mozilla.javascript.Scriptable
NOT_FOUND
-
Constructor Summary
ConstructorsConstructorDescriptionHybridObject
(org.mozilla.javascript.Scriptable scriptable, JsValueAdapter jsValueAdapter) -
Method Summary
Modifier and TypeMethodDescriptionvoid
delete
(int index) void
get
(int index, org.mozilla.javascript.Scriptable start) getDefaultValue
(Class hint) Object[]
getIds()
org.mozilla.javascript.Scriptable
getProperty
(String name) org.mozilla.javascript.Scriptable
boolean
has
(int index, org.mozilla.javascript.Scriptable start) boolean
boolean
hasInstance
(org.mozilla.javascript.Scriptable instance) void
void
void
setParentScope
(org.mozilla.javascript.Scriptable parent) void
setPrototype
(org.mozilla.javascript.Scriptable prototype)
-
Constructor Details
-
HybridObject
-
-
Method Details
-
getProperty
- Specified by:
getProperty
in interfaceorg.apache.sling.scripting.sightly.Record<Object>
-
getPropertyNames
- Specified by:
getPropertyNames
in interfaceorg.apache.sling.scripting.sightly.Record<Object>
-
getClassName
- Specified by:
getClassName
in interfaceorg.mozilla.javascript.Scriptable
-
get
- Specified by:
get
in interfaceorg.mozilla.javascript.Scriptable
-
get
- Specified by:
get
in interfaceorg.mozilla.javascript.Scriptable
-
has
- Specified by:
has
in interfaceorg.mozilla.javascript.Scriptable
-
has
public boolean has(int index, org.mozilla.javascript.Scriptable start) - Specified by:
has
in interfaceorg.mozilla.javascript.Scriptable
-
put
- Specified by:
put
in interfaceorg.mozilla.javascript.Scriptable
-
put
- Specified by:
put
in interfaceorg.mozilla.javascript.Scriptable
-
delete
- Specified by:
delete
in interfaceorg.mozilla.javascript.Scriptable
-
delete
public void delete(int index) - Specified by:
delete
in interfaceorg.mozilla.javascript.Scriptable
-
getPrototype
public org.mozilla.javascript.Scriptable getPrototype()- Specified by:
getPrototype
in interfaceorg.mozilla.javascript.Scriptable
-
setPrototype
public void setPrototype(org.mozilla.javascript.Scriptable prototype) - Specified by:
setPrototype
in interfaceorg.mozilla.javascript.Scriptable
-
getParentScope
public org.mozilla.javascript.Scriptable getParentScope()- Specified by:
getParentScope
in interfaceorg.mozilla.javascript.Scriptable
-
setParentScope
public void setParentScope(org.mozilla.javascript.Scriptable parent) - Specified by:
setParentScope
in interfaceorg.mozilla.javascript.Scriptable
-
getIds
- Specified by:
getIds
in interfaceorg.mozilla.javascript.Scriptable
-
getDefaultValue
- Specified by:
getDefaultValue
in interfaceorg.mozilla.javascript.Scriptable
-
hasInstance
public boolean hasInstance(org.mozilla.javascript.Scriptable instance) - Specified by:
hasInstance
in interfaceorg.mozilla.javascript.Scriptable
-