接口 XposedInterface.CtorInvoker<T>
- 类型参数:
T- The type of the constructor
- 所有超级接口:
XposedInterface.Invoker<XposedInterface.CtorInvoker<T>,Constructor<T>>
- 封闭接口:
XposedInterface
public static interface XposedInterface.CtorInvoker<T>
extends XposedInterface.Invoker<XposedInterface.CtorInvoker<T>,Constructor<T>>
Invoker for a constructor.
-
嵌套类概要
从接口继承的嵌套类/接口 io.github.libxposed.api.XposedInterface.Invoker
XposedInterface.Invoker.Type -
方法概要
修饰符和类型方法说明newInstance(Object... args) Creates a new instance through the hook chain determined by the invoker's type.<U> UnewInstanceSpecial(Class<U> subClass, Object... args) Creates a new instance of the given subclass, but initializes it with a parent constructor.从接口继承的方法 io.github.libxposed.api.XposedInterface.Invoker
invoke, invokeSpecial, setType
-
方法详细资料
-
newInstance
@NonNull T newInstance(Object... args) throws InvocationTargetException, IllegalArgumentException, IllegalAccessException, InstantiationException Creates a new instance through the hook chain determined by the invoker's type.- 参数:
args- The arguments used for the construction- 返回:
- The instance created and initialized by the constructor
- 抛出:
InvocationTargetExceptionIllegalArgumentExceptionIllegalAccessExceptionInstantiationException- 另请参阅:
-
newInstanceSpecial
@NonNull <U> U newInstanceSpecial(@NonNull Class<U> subClass, Object... args) throws InvocationTargetException, IllegalArgumentException, IllegalAccessException, InstantiationException Creates a new instance of the given subclass, but initializes it with a parent constructor. This could leave the object in an invalid state, where the subclass constructor is not called and the fields of the subclass are not initialized.This method is useful when you need to initialize some fields in the subclass by yourself.
- 类型参数:
U- The type of the subclass- 参数:
subClass- The subclass to create a new instanceargs- The arguments used for the construction- 返回:
- The instance of subclass initialized by the constructor
- 抛出:
InvocationTargetExceptionIllegalArgumentExceptionIllegalAccessExceptionInstantiationException- 另请参阅:
-