Package io.sundr.model
Class MethodFluent<A extends MethodFluent<A>>
- java.lang.Object
-
- io.sundr.builder.BaseFluent<A>
-
- io.sundr.model.AttributeSupportFluent<A>
-
- io.sundr.model.ModifierSupportFluent<A>
-
- io.sundr.model.MethodFluent<A>
-
- Direct Known Subclasses:
MethodBuilder,TypeDefFluent.ConstructorsNested,TypeDefFluent.MethodsNested
public class MethodFluent<A extends MethodFluent<A>> extends ModifierSupportFluent<A>
Generated
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classMethodFluent.AnnotationsNested<N>classMethodFluent.ArgumentsNested<N>classMethodFluent.BlockNested<N>classMethodFluent.ClassRefReturnTypeNested<N>classMethodFluent.ExceptionsNested<N>classMethodFluent.ParametersNested<N>classMethodFluent.PrimitiveRefReturnTypeNested<N>classMethodFluent.TypeParamRefReturnTypeNested<N>classMethodFluent.VoidRefReturnTypeNested<N>classMethodFluent.WildcardRefReturnTypeNested<N>-
Nested classes/interfaces inherited from class io.sundr.model.ModifierSupportFluent
ModifierSupportFluent.ModifiersNested<N>
-
-
Field Summary
-
Fields inherited from class io.sundr.builder.BaseFluent
_visitables
-
-
Constructor Summary
Constructors Constructor Description MethodFluent()MethodFluent(Method instance)
-
Method Summary
-
Methods inherited from class io.sundr.model.ModifierSupportFluent
buildModifiers, copyInstance, editModifiers, editOrNewModifiers, editOrNewModifiersLike, hasModifiers, withModifiers, withNewModifiers, withNewModifiersLike
-
Methods inherited from class io.sundr.model.AttributeSupportFluent
addToAttributes, addToAttributes, copyInstance, getAttributes, hasAttributes, removeFromAttributes, removeFromAttributes, withAttributes
-
Methods inherited from class io.sundr.builder.BaseFluent
aggregate, aggregate, build, build, builderOf, getVisitableMap
-
-
-
-
Constructor Detail
-
MethodFluent
public MethodFluent()
-
MethodFluent
public MethodFluent(Method instance)
-
-
Method Detail
-
copyInstance
protected void copyInstance(Method instance)
-
addAllToComments
public A addAllToComments(Collection<String> items)
-
removeAllFromComments
public A removeAllFromComments(Collection<String> items)
-
getComment
public String getComment(int index)
-
getFirstComment
public String getFirstComment()
-
getLastComment
public String getLastComment()
-
hasComments
public boolean hasComments()
-
addToAnnotations
public A addToAnnotations(int index, AnnotationRef item)
-
setToAnnotations
public A setToAnnotations(int index, AnnotationRef item)
-
addToAnnotations
public A addToAnnotations(AnnotationRef... items)
-
addAllToAnnotations
public A addAllToAnnotations(Collection<AnnotationRef> items)
-
removeFromAnnotations
public A removeFromAnnotations(AnnotationRef... items)
-
removeAllFromAnnotations
public A removeAllFromAnnotations(Collection<AnnotationRef> items)
-
removeMatchingFromAnnotations
public A removeMatchingFromAnnotations(Predicate<AnnotationRefBuilder> predicate)
-
buildAnnotations
public List<AnnotationRef> buildAnnotations()
-
buildAnnotation
public AnnotationRef buildAnnotation(int index)
-
buildFirstAnnotation
public AnnotationRef buildFirstAnnotation()
-
buildLastAnnotation
public AnnotationRef buildLastAnnotation()
-
buildMatchingAnnotation
public AnnotationRef buildMatchingAnnotation(Predicate<AnnotationRefBuilder> predicate)
-
hasMatchingAnnotation
public boolean hasMatchingAnnotation(Predicate<AnnotationRefBuilder> predicate)
-
withAnnotations
public A withAnnotations(List<AnnotationRef> annotations)
-
withAnnotations
public A withAnnotations(AnnotationRef... annotations)
-
hasAnnotations
public boolean hasAnnotations()
-
addNewAnnotation
public MethodFluent.AnnotationsNested<A> addNewAnnotation()
-
addNewAnnotationLike
public MethodFluent.AnnotationsNested<A> addNewAnnotationLike(AnnotationRef item)
-
setNewAnnotationLike
public MethodFluent.AnnotationsNested<A> setNewAnnotationLike(int index, AnnotationRef item)
-
editAnnotation
public MethodFluent.AnnotationsNested<A> editAnnotation(int index)
-
editFirstAnnotation
public MethodFluent.AnnotationsNested<A> editFirstAnnotation()
-
editLastAnnotation
public MethodFluent.AnnotationsNested<A> editLastAnnotation()
-
editMatchingAnnotation
public MethodFluent.AnnotationsNested<A> editMatchingAnnotation(Predicate<AnnotationRefBuilder> predicate)
-
addToParameters
public A addToParameters(int index, TypeParamDef item)
-
setToParameters
public A setToParameters(int index, TypeParamDef item)
-
addToParameters
public A addToParameters(TypeParamDef... items)
-
addAllToParameters
public A addAllToParameters(Collection<TypeParamDef> items)
-
removeFromParameters
public A removeFromParameters(TypeParamDef... items)
-
removeAllFromParameters
public A removeAllFromParameters(Collection<TypeParamDef> items)
-
removeMatchingFromParameters
public A removeMatchingFromParameters(Predicate<TypeParamDefBuilder> predicate)
-
buildParameters
public List<TypeParamDef> buildParameters()
-
buildParameter
public TypeParamDef buildParameter(int index)
-
buildFirstParameter
public TypeParamDef buildFirstParameter()
-
buildLastParameter
public TypeParamDef buildLastParameter()
-
buildMatchingParameter
public TypeParamDef buildMatchingParameter(Predicate<TypeParamDefBuilder> predicate)
-
hasMatchingParameter
public boolean hasMatchingParameter(Predicate<TypeParamDefBuilder> predicate)
-
withParameters
public A withParameters(List<TypeParamDef> parameters)
-
withParameters
public A withParameters(TypeParamDef... parameters)
-
hasParameters
public boolean hasParameters()
-
addNewParameter
public MethodFluent.ParametersNested<A> addNewParameter()
-
addNewParameterLike
public MethodFluent.ParametersNested<A> addNewParameterLike(TypeParamDef item)
-
setNewParameterLike
public MethodFluent.ParametersNested<A> setNewParameterLike(int index, TypeParamDef item)
-
editParameter
public MethodFluent.ParametersNested<A> editParameter(int index)
-
editFirstParameter
public MethodFluent.ParametersNested<A> editFirstParameter()
-
editLastParameter
public MethodFluent.ParametersNested<A> editLastParameter()
-
editMatchingParameter
public MethodFluent.ParametersNested<A> editMatchingParameter(Predicate<TypeParamDefBuilder> predicate)
-
getName
public String getName()
-
hasName
public boolean hasName()
-
buildReturnType
public TypeRef buildReturnType()
-
hasReturnType
public boolean hasReturnType()
-
withNewClassRefReturnType
public MethodFluent.ClassRefReturnTypeNested<A> withNewClassRefReturnType()
-
withNewClassRefReturnTypeLike
public MethodFluent.ClassRefReturnTypeNested<A> withNewClassRefReturnTypeLike(ClassRef item)
-
withNewPrimitiveRefReturnType
public MethodFluent.PrimitiveRefReturnTypeNested<A> withNewPrimitiveRefReturnType()
-
withNewPrimitiveRefReturnTypeLike
public MethodFluent.PrimitiveRefReturnTypeNested<A> withNewPrimitiveRefReturnTypeLike(PrimitiveRef item)
-
withNewVoidRefReturnType
public MethodFluent.VoidRefReturnTypeNested<A> withNewVoidRefReturnType()
-
withNewVoidRefReturnTypeLike
public MethodFluent.VoidRefReturnTypeNested<A> withNewVoidRefReturnTypeLike(VoidRef item)
-
withNewTypeParamRefReturnType
public MethodFluent.TypeParamRefReturnTypeNested<A> withNewTypeParamRefReturnType()
-
withNewTypeParamRefReturnTypeLike
public MethodFluent.TypeParamRefReturnTypeNested<A> withNewTypeParamRefReturnTypeLike(TypeParamRef item)
-
withNewWildcardRefReturnType
public MethodFluent.WildcardRefReturnTypeNested<A> withNewWildcardRefReturnType()
-
withNewWildcardRefReturnTypeLike
public MethodFluent.WildcardRefReturnTypeNested<A> withNewWildcardRefReturnTypeLike(WildcardRef item)
-
addAllToArguments
public A addAllToArguments(Collection<Property> items)
-
removeAllFromArguments
public A removeAllFromArguments(Collection<Property> items)
-
removeMatchingFromArguments
public A removeMatchingFromArguments(Predicate<PropertyBuilder> predicate)
-
buildArgument
public Property buildArgument(int index)
-
buildFirstArgument
public Property buildFirstArgument()
-
buildLastArgument
public Property buildLastArgument()
-
buildMatchingArgument
public Property buildMatchingArgument(Predicate<PropertyBuilder> predicate)
-
hasMatchingArgument
public boolean hasMatchingArgument(Predicate<PropertyBuilder> predicate)
-
hasArguments
public boolean hasArguments()
-
addNewArgument
public MethodFluent.ArgumentsNested<A> addNewArgument()
-
addNewArgumentLike
public MethodFluent.ArgumentsNested<A> addNewArgumentLike(Property item)
-
setNewArgumentLike
public MethodFluent.ArgumentsNested<A> setNewArgumentLike(int index, Property item)
-
editArgument
public MethodFluent.ArgumentsNested<A> editArgument(int index)
-
editFirstArgument
public MethodFluent.ArgumentsNested<A> editFirstArgument()
-
editLastArgument
public MethodFluent.ArgumentsNested<A> editLastArgument()
-
editMatchingArgument
public MethodFluent.ArgumentsNested<A> editMatchingArgument(Predicate<PropertyBuilder> predicate)
-
isVarArgPreferred
public boolean isVarArgPreferred()
-
withVarArgPreferred
public A withVarArgPreferred(boolean varArgPreferred)
-
hasVarArgPreferred
public boolean hasVarArgPreferred()
-
addAllToExceptions
public A addAllToExceptions(Collection<ClassRef> items)
-
removeAllFromExceptions
public A removeAllFromExceptions(Collection<ClassRef> items)
-
removeMatchingFromExceptions
public A removeMatchingFromExceptions(Predicate<ClassRefBuilder> predicate)
-
buildException
public ClassRef buildException(int index)
-
buildFirstException
public ClassRef buildFirstException()
-
buildLastException
public ClassRef buildLastException()
-
buildMatchingException
public ClassRef buildMatchingException(Predicate<ClassRefBuilder> predicate)
-
hasMatchingException
public boolean hasMatchingException(Predicate<ClassRefBuilder> predicate)
-
hasExceptions
public boolean hasExceptions()
-
addNewException
public MethodFluent.ExceptionsNested<A> addNewException()
-
addNewExceptionLike
public MethodFluent.ExceptionsNested<A> addNewExceptionLike(ClassRef item)
-
setNewExceptionLike
public MethodFluent.ExceptionsNested<A> setNewExceptionLike(int index, ClassRef item)
-
editException
public MethodFluent.ExceptionsNested<A> editException(int index)
-
editFirstException
public MethodFluent.ExceptionsNested<A> editFirstException()
-
editLastException
public MethodFluent.ExceptionsNested<A> editLastException()
-
editMatchingException
public MethodFluent.ExceptionsNested<A> editMatchingException(Predicate<ClassRefBuilder> predicate)
-
isDefaultMethod
public boolean isDefaultMethod()
-
withDefaultMethod
public A withDefaultMethod(boolean defaultMethod)
-
hasDefaultMethod
public boolean hasDefaultMethod()
-
buildBlock
public Block buildBlock()
-
hasBlock
public boolean hasBlock()
-
withNewBlock
public MethodFluent.BlockNested<A> withNewBlock()
-
withNewBlockLike
public MethodFluent.BlockNested<A> withNewBlockLike(Block item)
-
editBlock
public MethodFluent.BlockNested<A> editBlock()
-
editOrNewBlock
public MethodFluent.BlockNested<A> editOrNewBlock()
-
editOrNewBlockLike
public MethodFluent.BlockNested<A> editOrNewBlockLike(Block item)
-
equals
public boolean equals(Object o)
- Overrides:
equalsin classModifierSupportFluent<A extends MethodFluent<A>>
-
hashCode
public int hashCode()
- Overrides:
hashCodein classModifierSupportFluent<A extends MethodFluent<A>>
-
toString
public String toString()
- Overrides:
toStringin classModifierSupportFluent<A extends MethodFluent<A>>
-
builder
protected static <T> VisitableBuilder<T,?> builder(Object item)
-
withVarArgPreferred
public A withVarArgPreferred()
-
withDefaultMethod
public A withDefaultMethod()
-
-