TPTP 4.6.0 Platform Project
Public API Specification

org.eclipse.tptp.platform.analysis.codereview.java.templates
Class TemplateAvoidClassInstanceCreation

java.lang.Object
  extended by org.eclipse.tptp.platform.analysis.core.element.AbstractAnalysisElement
      extended by org.eclipse.tptp.platform.analysis.core.rule.AbstractAnalysisRule
          extended by org.eclipse.tptp.platform.analysis.codereview.java.templates.TemplateAvoidClassInstanceCreation
All Implemented Interfaces:
org.eclipse.core.runtime.IExecutableExtension, IAnalysisElement, IAnalysisRule

public class TemplateAvoidClassInstanceCreation
extends AbstractAnalysisRule

This class implements a rule template which generates a result for each matched class instance creation and super constructor invocation.

The template interprets all of the following optional rule variables:

CLASS - the name of the class the defines the method

PARAMETER_TYPES - a comma separated list of of parameter types


Field Summary
 
Fields inherited from class org.eclipse.tptp.platform.analysis.core.element.AbstractAnalysisElement
CATEGORY_ELEMENT_TYPE, COMBO_VALUE, DETAIL_PROVIDER, PROVIDER_ELEMENT_TYPE, PROVIDER_MANAGER_ELEMENT_TYPE, RESULT_ELEMENT_TYPE, RULE_ELEMENT_TYPE
 
Constructor Summary
TemplateAvoidClassInstanceCreation()
           
 
Method Summary
 void analyze(AnalysisHistory history)
          Analyze this rule
 
Methods inherited from class org.eclipse.tptp.platform.analysis.core.rule.AbstractAnalysisRule
addHistoryResultSet, getIconName, getLabelWithParameters, getLabelWithVariables, getOwnedElements, getQuickFix, getQuickFixCount, getQuickFixIterator, getViewer, hasQuickFixes, isCustom, removeHistoryResultSet, setCustom, setInitializationData, setQuickFixId
 
Methods inherited from class org.eclipse.tptp.platform.analysis.core.element.AbstractAnalysisElement
addDetailProvider, addHistoryResultSet, addOwnedElement, addOwnedElements, addParameter, addParameters, deleteHistoryResults, dispose, getDetailProviders, getElementType, getExecutionHistory, getExternalDataMap, getHelpID, getHistoryResults, getId, getLabel, getOwner, getOwnerId, getParameter, getParameterCount, getParameterList, getPluginId, getProvider, getProviderManager, getViewerID, getVisibleParameterCount, postAnalyze, preAnalyze, removeHistoryResultSet, setElementType, setExternalDataMap, setHelpID, setIconName, setId, setInitializationData, setLabel, setOwner, setOwnerId, setPluginId, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.eclipse.tptp.platform.analysis.core.rule.IAnalysisRule
addParameter, addParameters, getParameter, getParameterCount, getParameterList, getProvider, getVisibleParameterCount
 
Methods inherited from interface org.eclipse.tptp.platform.analysis.core.element.IAnalysisElement
addDetailProvider, addHistoryResultSet, addOwnedElement, addOwnedElements, dispose, getDetailProviders, getElementType, getExternalDataMap, getHelpID, getHistoryResults, getId, getLabel, getOwner, getPluginId, preAnalyze, setElementType, setExternalDataMap, setHelpID, setIconName, setId, setLabel, setOwner, setPluginId
 

Constructor Detail

TemplateAvoidClassInstanceCreation

public TemplateAvoidClassInstanceCreation()
Method Detail

analyze

public void analyze(AnalysisHistory history)
Analyze this rule

Specified by:
analyze in interface IAnalysisRule
Specified by:
analyze in class AbstractAnalysisRule
Parameters:
history - A reference to the history record for this analysis

TPTP 4.6.0 Platform Project
Public API Specification