All Downloads are FREE. Search and download functionalities are using the official Maven repository.

it.auties.protobuf.tool.util.AstElements Maven / Gradle / Ivy

There is a newer version: 2.0.5
Show newest version
package it.auties.protobuf.tool.util;

import com.fasterxml.jackson.annotation.JsonCreator;
import it.auties.protobuf.base.ProtobufMessage;
import it.auties.protobuf.base.ProtobufName;
import it.auties.protobuf.base.ProtobufProperty;
import lombok.experimental.UtilityClass;

import java.util.*;
import java.util.function.Predicate;
import java.util.stream.Stream;

@UtilityClass
public class AstElements {
    public final String PROTOBUF_MESSAGE = ProtobufMessage.class.getName();
    public final String PROTOBUF_MESSAGE_NAME = ProtobufName.class.getName();
    public final String PROTOBUF_PROPERTY = ProtobufProperty.class.getName();
    public final String JSON_CREATOR = JsonCreator.class.getName();
    public final String ARRAYS = Arrays.class.getName();
    public final String STREAM = Stream.class.getName();
    public final String OBJECT = Object.class.getName();
    public final String PREDICATE = Predicate.class.getName();
    public final String DEPRECATED = Deprecated.class.getName();
    public final String NON_NULL = findLombokAnnotation("NonNull");
    public final String BUILDER = findLombokAnnotation("Builder");
    public final String ALL_ARGS_CONSTRUCTOR = findLombokAnnotation("AllArgsConstructor");
    public final String GETTER = findLombokAnnotation("Getter");
    public final String DATA = findLombokAnnotation("Data");
    public final String DEFAULT = findLombokAnnotation("Builder.Default");
    public final String JACKSONIZED = findLombokAnnotation("extern.jackson.Jacksonized");
    public static final String LIST = List.class.getName();
    public static final String ARRAY_LIST = ArrayList.class.getName();
    public static final String COLLECTION = Collection.class.getName();
    public static final String OVERRIDE = Override.class.getName();
    public static final String OPTIONAL = Optional.class.getName();

    private static String findLombokAnnotation(String annotation){
        return "lombok.%s".formatted(annotation);
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy