Название: Java Interceptor Development with ByteBuddy: Fundamental Автор: Eric Fong Издательство: MillionStrengthKnowledge Год: 2020 Страниц: 256 Язык: английский Формат: pdf, azw3, epub Размер: 20.3 MB
ByteBuddy is an open source Java based library for Java bytecode generation and manipulation. ByteBuddy is licensed under Apache License Version 2.0, and is freely available on Github. This book provides fundamental knowledge and learn by example guideline on how to develop interceptor and generate code using ByteBuddy. The book provides many easy-to-understand and concise sample codes. The learner can expect to learn these skills and knowledge from this book:
(1) Intercept Java code using on method enter advice, one method exit advice, and around advice. (2) Learn to generate code during maven build time, and integrate code generation with the maven build process (19 chapters). (3) ByteBuddy supports instrumentation that can inspect and modify existing Java bytecode. These techniques will be explained in this book:
• Add new constructor, method and instance variable • Remove existing constructor, method and instance variable • Modify the value of instance variable • Modify the value of method parameter • Inspect the existing Java class structure, constructor signature, method signature, and instance variable • Generate new generic Java class, constructor, method, and instance variable (upper bound, lower bound, multiple bound, wildcard, parameterized type, method type argument) • Search and replace code in the method • Add and remove annotation that is annotated on Java class, constructor, method, instance variable, and parameter • Add and modify Java inner class (add first and second level inner class, intercepting inner class and anonymous class) • Generate new Java class, Java interface, enum, annotation, and abstract class • Generate simple method and lambda expression • Sharing data between advice codes
(5) Introduction to Java agent development with Java Instrumentation API and ByteBuddy, which can intercept JDK core class (one chapter only)
This book does not cover:
• How to instrument Record component • How to instrument Java native method • How to instrument lambda expression • How to generate anonymous class • How to instrument Java bytecode using bytecode instruction, for example, stack manipulation, and ByteCodeAppender
Скачать Java Interceptor Development with ByteBuddy: Fundamental
Внимание
Уважаемый посетитель, Вы зашли на сайт как незарегистрированный пользователь.
Мы рекомендуем Вам зарегистрироваться либо войти на сайт под своим именем.
Информация
Посетители, находящиеся в группе Гости, не могут оставлять комментарии к данной публикации.