1
2
3
4
5
6
7
8
9
10
11
12
13
14
15 package org.htmlunit.javascript;
16
17 import java.io.Serializable;
18
19 import org.htmlunit.corejs.javascript.Context;
20 import org.htmlunit.corejs.javascript.Function;
21 import org.htmlunit.corejs.javascript.Scriptable;
22
23
24
25
26
27
28
29
30 public class FunctionWrapper implements Function, Serializable {
31 private final Function wrapped_;
32
33
34
35
36
37 public FunctionWrapper(final Function wrapped) {
38 wrapped_ = wrapped;
39 }
40
41
42
43
44 @Override
45 public Object call(final Context cx, final Scriptable scope, final Scriptable thisObj, final Object[] args) {
46 return wrapped_.call(cx, scope, thisObj, args);
47 }
48
49
50
51
52 @Override
53 public String getClassName() {
54 return wrapped_.getClassName();
55 }
56
57
58
59
60 @Override
61 public Scriptable construct(final Context cx, final Scriptable scope, final Object[] args) {
62 return wrapped_.construct(cx, scope, args);
63 }
64
65
66
67
68 @Override
69 public Object get(final String name, final Scriptable start) {
70 return wrapped_.get(name, start);
71 }
72
73
74
75
76 @Override
77 public Object get(final int index, final Scriptable start) {
78 return wrapped_.get(index, start);
79 }
80
81
82
83
84 @Override
85 public boolean has(final String name, final Scriptable start) {
86 return wrapped_.has(name, start);
87 }
88
89
90
91
92 @Override
93 public boolean has(final int index, final Scriptable start) {
94 return wrapped_.has(index, start);
95 }
96
97
98
99
100 @Override
101 public void put(final String name, final Scriptable start, final Object value) {
102 wrapped_.put(name, wrapped_, value);
103 }
104
105
106
107
108 @Override
109 public void put(final int index, final Scriptable start, final Object value) {
110 wrapped_.put(index, wrapped_, value);
111 }
112
113
114
115
116 @Override
117 public void delete(final String name) {
118 wrapped_.delete(name);
119 }
120
121
122
123
124 @Override
125 public void delete(final int index) {
126 wrapped_.delete(index);
127 }
128
129
130
131
132 @Override
133 public Scriptable getPrototype() {
134 return wrapped_.getPrototype();
135 }
136
137
138
139
140 @Override
141 public void setPrototype(final Scriptable prototype) {
142 wrapped_.setPrototype(prototype);
143 }
144
145
146
147
148 @Override
149 public Scriptable getParentScope() {
150 return wrapped_.getParentScope();
151 }
152
153
154
155
156 @Override
157 public void setParentScope(final Scriptable parent) {
158 wrapped_.setParentScope(parent);
159 }
160
161
162
163
164 @Override
165 public Object[] getIds() {
166 return wrapped_.getIds();
167 }
168
169
170
171
172 @Override
173 public Object getDefaultValue(final Class<?> hint) {
174 return wrapped_.getDefaultValue(hint);
175 }
176
177
178
179
180 @Override
181 public boolean hasInstance(final Scriptable instance) {
182 return wrapped_.hasInstance(instance);
183 }
184 }