public abstract static class SnippetTemplate.SnippetInfo extends Object
ResolvedJavaMethod
of the snippet, together with some information about the
method that needs to be computed only once. The SnippetTemplate.SnippetInfo
should be created once
per snippet and then cached.Modifier and Type | Class and Description |
---|---|
(package private) static class |
SnippetTemplate.SnippetInfo.Lazy
Lazily constructed parts of
SnippetTemplate.SnippetInfo . |
Modifier and Type | Field and Description |
---|---|
private DebugMetric |
instantiationCounter
Counts instantiations of all templates derived from this snippet.
|
private DebugTimer |
instantiationTimer
Times instantiations of all templates derived form this snippet.
|
protected ResolvedJavaMethod |
method |
protected ResolvedJavaMethod |
original |
protected LocationIdentity[] |
privateLocations |
private int |
templateCount |
Modifier | Constructor and Description |
---|---|
protected |
SnippetInfo(ResolvedJavaMethod method,
LocationIdentity[] privateLocations) |
Modifier and Type | Method and Description |
---|---|
ResolvedJavaMethod |
getMethod() |
int |
getParameterCount() |
String |
getParameterName(int paramIdx) |
boolean |
isConstantParameter(int paramIdx) |
boolean |
isVarargsParameter(int paramIdx) |
protected abstract SnippetTemplate.SnippetInfo.Lazy |
lazy() |
(package private) void |
notifyNewTemplate() |
void |
setOriginalMethod(ResolvedJavaMethod original) |
String |
toString() |
protected final ResolvedJavaMethod method
protected ResolvedJavaMethod original
protected final LocationIdentity[] privateLocations
private final DebugTimer instantiationTimer
SnippetTemplate.instantiationTimer
private final DebugMetric instantiationCounter
SnippetTemplate.instantiationCounter
private int templateCount
protected SnippetInfo(ResolvedJavaMethod method, LocationIdentity[] privateLocations)
protected abstract SnippetTemplate.SnippetInfo.Lazy lazy()
void notifyNewTemplate()
public ResolvedJavaMethod getMethod()
public int getParameterCount()
public void setOriginalMethod(ResolvedJavaMethod original)
public boolean isConstantParameter(int paramIdx)
public boolean isVarargsParameter(int paramIdx)
public String getParameterName(int paramIdx)