public static class OverloadScanner.Overload extends Object
| Modifier and Type | Field and Description |
|---|---|
com.sun.tools.javac.tree.JCTree.JCMethodDecl |
coreMethod
The core method of the overload, that is to say the one holding the
implementation.
|
Map<Integer,com.sun.tools.javac.tree.JCTree> |
defaultValues
The default values for the parameters of the core method.
|
boolean |
isValid
Tells if this overload is valid wrt to JSweet conventions.
|
String |
methodName
The method name.
|
List<com.sun.tools.javac.tree.JCTree.JCMethodDecl> |
methods
The methods carrying the same name.
|
boolean |
printed
A flag to tell if this overload was printed out (used by the printer).
|
| Constructor and Description |
|---|
Overload() |
| Modifier and Type | Method and Description |
|---|---|
void |
calculate(com.sun.tools.javac.code.Types types,
com.sun.tools.javac.code.Symtab symtab)
Checks the validity of the overload and calculates the default values.
|
String |
getParameterName(int index)
Gets the parameter name at the given index for an invalid overload.
|
int |
getSmallerParameterCount()
Returns parameter count of the method having the fewer parameters.
|
void |
merge(com.sun.tools.javac.code.Types types,
OverloadScanner.Overload subOverload)
Merges the given overload with a subclass one.
|
String |
toString() |
public String methodName
public List<com.sun.tools.javac.tree.JCTree.JCMethodDecl> methods
public boolean isValid
public com.sun.tools.javac.tree.JCTree.JCMethodDecl coreMethod
public Map<Integer,com.sun.tools.javac.tree.JCTree> defaultValues
public boolean printed
public int getSmallerParameterCount()
public String getParameterName(int index)
index - the parameter's indexpublic void calculate(com.sun.tools.javac.code.Types types,
com.sun.tools.javac.code.Symtab symtab)
public void merge(com.sun.tools.javac.code.Types types,
OverloadScanner.Overload subOverload)