Package com.google.auto.value.processor
Class BuilderSpec
java.lang.Object
com.google.auto.value.processor.BuilderSpec
Support for AutoValue builders.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescription(package private) class
Representation of anAutoValue.Builder
class or interface.static class
Information about a builder property getter, referenced from the autovalue.vm template.static class
Information about a property setter, referenced from the autovalue.vm template. -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final TypeElement
private static final com.google.common.collect.ImmutableSet<ElementKind>
private final ErrorReporter
private final ProcessingEnvironment
-
Constructor Summary
ConstructorsConstructorDescriptionBuilderSpec
(TypeElement autoValueClass, ProcessingEnvironment processingEnv, ErrorReporter errorReporter) -
Method Summary
Modifier and TypeMethodDescriptionprivate Set<ExecutableElement>
abstractMethods
(TypeElement typeElement) private Optional<BuilderSpec.Builder>
builderFrom
(TypeElement builderTypeElement) Returns a representation of the given@AutoValue.Builder
class or interface.(package private) Optional<BuilderSpec.Builder>
Determines if the@AutoValue
class for this instance has a correct nested@AutoValue.Builder
class or interface and return a representation of it in anOptional
if so.private static boolean
private String
-
Field Details
-
autoValueClass
-
processingEnv
-
errorReporter
-
CLASS_OR_INTERFACE
-
-
Constructor Details
-
BuilderSpec
BuilderSpec(TypeElement autoValueClass, ProcessingEnvironment processingEnv, ErrorReporter errorReporter)
-
-
Method Details
-
getBuilder
Optional<BuilderSpec.Builder> getBuilder()Determines if the@AutoValue
class for this instance has a correct nested@AutoValue.Builder
class or interface and return a representation of it in anOptional
if so. -
builderFrom
Returns a representation of the given@AutoValue.Builder
class or interface. If the class or interface has abstract methods that could not be part of any builder, emits error messages and returns Optional.empty(). -
sameTypeParameters
-
abstractMethods
-
typeParamsString
-