本文整理汇总了Java中net.bytebuddy.implementation.bytecode.ByteCodeAppender.Simple方法的典型用法代码示例。如果您正苦于以下问题:Java ByteCodeAppender.Simple方法的具体用法?Java ByteCodeAppender.Simple怎么用?Java ByteCodeAppender.Simple使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类net.bytebuddy.implementation.bytecode.ByteCodeAppender
的用法示例。
在下文中一共展示了ByteCodeAppender.Simple方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: prepend
import net.bytebuddy.implementation.bytecode.ByteCodeAppender; //导入方法依赖的package包/类
@Override
public Record prepend(ByteCodeAppender byteCodeAppender) {
return new ForDefinedMethod.WithBody(methodDescription, new ByteCodeAppender.Compound(byteCodeAppender,
new ByteCodeAppender.Simple(DefaultValue.of(methodDescription.getReturnType()), MethodReturn.of(methodDescription.getReturnType()))));
}
示例2: appender
import net.bytebuddy.implementation.bytecode.ByteCodeAppender; //导入方法依赖的package包/类
@Override
public ByteCodeAppender appender(Target implementationTarget) {
return new ByteCodeAppender.Simple(NullConstant.INSTANCE, MethodReturn.REFERENCE);
}
示例3: storeIn
import net.bytebuddy.implementation.bytecode.ByteCodeAppender; //导入方法依赖的package包/类
/**
* Returns a stack manipulation where the represented value is stored in the given field.
*
* @param fieldDescription A static field in which the value is to be stored.
* @return A byte code appender that represents this storage.
*/
protected ByteCodeAppender storeIn(FieldDescription fieldDescription) {
return new ByteCodeAppender.Simple(this, FieldAccess.forField(fieldDescription).write());
}
示例4: Simple
import net.bytebuddy.implementation.bytecode.ByteCodeAppender; //导入方法依赖的package包/类
/**
* Creates a new simple instrumentation for the given stack manipulations which are summarized in a
* byte code appender that defines any requested method by these manipulations.
*
* @param stackManipulation The stack manipulation to apply in their order of application.
*/
public Simple(StackManipulation... stackManipulation) {
byteCodeAppender = new ByteCodeAppender.Simple(stackManipulation);
}