public class FormatterTreeUtil.FormatCall extends Object
Constructor and Description |
---|
FormatCall(MethodInvocationTree node,
AnnotatedTypeFactory atypeFactory) |
Modifier and Type | Method and Description |
---|---|
ConversionCategory[] |
getFormatCategories()
Returns the conversion category for every parameter.
|
FormatterTreeUtil.Result<FormatterTreeUtil.InvocationType> |
getInvocationType()
Returns the type of method invocation.
|
FormatterTreeUtil.Result<TypeMirror>[] |
getParamTypes()
Returns the type of the function's parameters.
|
FormatterTreeUtil.Result<String> |
isIllegalFormat()
Returns an error description if the format string cannot be satisfied.
|
boolean |
isParameterNull(TypeMirror type)
Checks if the parameter returned from
getParamTypes() is a null
expression. |
boolean |
isValidParameter(ConversionCategory formatCat,
TypeMirror paramType)
Checks if the type of a parameter returned from
getParamTypes() is valid for the
passed ConversionCategory. |
public FormatCall(MethodInvocationTree node, AnnotatedTypeFactory atypeFactory)
public final FormatterTreeUtil.Result<String> isIllegalFormat()
public final FormatterTreeUtil.Result<FormatterTreeUtil.InvocationType> getInvocationType()
FormatterTreeUtil.InvocationType
public final ConversionCategory[] getFormatCategories()
ConversionCategory
public final FormatterTreeUtil.Result<TypeMirror>[] getParamTypes()
isValidParameter
and isParameterNull
to work with the result.public final boolean isValidParameter(ConversionCategory formatCat, TypeMirror paramType)
getParamTypes()
is valid for the
passed ConversionCategory.public final boolean isParameterNull(TypeMirror type)
getParamTypes()
is a null
expression.