software.coley.cafedude.tree.visitor.writer.AnnotationWriter Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of cafedude-tree Show documentation
Show all versions of cafedude-tree Show documentation
Tree module for CafeDude, containing a simplified intermediate model for classes
package software.coley.cafedude.tree.visitor.writer;
import software.coley.cafedude.classfile.annotation.*;
import software.coley.cafedude.classfile.constant.CpUtf8;
import software.coley.cafedude.tree.Constant;
import software.coley.cafedude.tree.visitor.AnnotationArrayVisitor;
import software.coley.cafedude.tree.visitor.AnnotationVisitor;
import javax.annotation.Nonnull;
import java.util.HashMap;
import java.util.Map;
import java.util.function.Consumer;
/**
* Annotation visitor implementation to write back to a {@link Annotation}.
*
* @author Justus Garbe
*/
public class AnnotationWriter implements AnnotationVisitor {
private final Symbols symbols;
private final Map values = new HashMap<>();
private final Consumer