Class ClassWriter
java.lang.Object
com.strobel.reflection.emit.ClassWriter
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final CodeStreamprivate final CodeStreamprivate final CodeStreamprivate final TypeBuilder<?> private static final intprivate static final intprivate static final int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate intprivate voidendAttribute(int index) private voidendAttributes(int index, int count) private RetentionPolicygetAnnotationRetention(AnnotationBuilder<? extends Annotation> a) private List<ClassWriter.LocalInfo> getLocalInfo(MethodBuilder builder) private booleanneedsLocalVariableTableEntry(Type<?> localType) (package private) voidputChar(CodeStream buf, int op, int x) (package private) voidputInt(CodeStream buf, int adr, int x) private voidwriteAnnotation(AnnotationBuilder<? extends Annotation> a) private intwriteAttribute(String attributeName) private voidwriteAttributeType(Object value) private voidwriteBody(MethodBuilder method) voidwriteClass(CodeStream out) voidwriteClass(OutputStream out) private voidprivate intprivate voidwriteField(FieldBuilder field) private voidprivate intwriteFlagAttributes(long flags) private voidwriteInnerTypeInfo(Type<?> type) private intprivate intwriteJavaAnnotations(ReadOnlyList<AnnotationBuilder<? extends Annotation>> annotations) private intwriteMemberAttributes(MemberInfo member) private voidwriteMethod(MethodBuilder method) private voidprivate int
-
Field Details
-
JAVA_MAGIC
private static final int JAVA_MAGIC- See Also:
-
DATA_BUFFER_SIZE
private static final int DATA_BUFFER_SIZE- See Also:
-
POOL_BUFFER_SIZE
private static final int POOL_BUFFER_SIZE- See Also:
-
_dataBuffer
-
_poolBuffer
-
_signatureBuffer
-
_typeBuilder
-
-
Constructor Details
-
ClassWriter
ClassWriter(TypeBuilder<?> typeBuilder)
-
-
Method Details
-
writeClass
- Throws:
IOException
-
writeClass
- Throws:
IOException
-
writeCore
private void writeCore() -
writeEnclosingMethodAttribute
-
writeInnerTypes
private int writeInnerTypes() -
writeInnerTypeInfo
-
writeFields
private void writeFields() -
writeField
-
writeMethods
private void writeMethods() -
writeMethod
-
writeBody
-
needsLocalVariableTableEntry
-
getLocalInfo
-
writeMemberAttributes
-
writeParameterAttributes
-
getAnnotationRetention
-
writeJavaAnnotations
-
writeAnnotation
-
writeAttributeType
-
writeAttribute
-
beginAttributes
private int beginAttributes() -
endAttributes
private void endAttributes(int index, int count) -
endAttribute
private void endAttribute(int index) -
writeFlagAttributes
private int writeFlagAttributes(long flags) -
putChar
-
putInt
-