You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you do not want to write annotation support yourself, you can use built-in `com.jsoniter.annotation.JsoniterAnnotationSupport`.
202
202
203
+
# No default constructor? No problem!
204
+
205
+
Jsoniter can work with class without default constructor. The extension can customize the constructor to be used for specific class. The constructor can also be a static method, instead of real constructor.
206
+
207
+
```java
208
+
publicinterfaceExtension {
209
+
// ...
210
+
CustomizedConstructorgetConstructor(Classclazz);
211
+
/// ...
212
+
}
213
+
214
+
publicclassCustomizedConstructor {
215
+
/**
216
+
* set to null if use constructor
217
+
* otherwise use static method
218
+
*/
219
+
publicString staticMethodName;
220
+
221
+
/**
222
+
* the parameters to call constructor or static method
0 commit comments