Class SourceEditorController
- java.lang.Object
-
- net.sourceforge.pmd.util.fxdesigner.app.AbstractController<MainDesignerController>
-
- net.sourceforge.pmd.util.fxdesigner.SourceEditorController
-
- All Implemented Interfaces:
javafx.fxml.Initializable,ApplicationComponent,SettingsOwner
public class SourceEditorController extends AbstractController<MainDesignerController>
One editor, i.e. source editor and ast tree view. TheNodeEditionCodeAreahandles the presentation of different types of nodes in separate layers. This class handles configuration, language selection and such.- Since:
- 6.0.0
- Author:
- Clément Fournier
-
-
Field Summary
-
Fields inherited from class net.sourceforge.pmd.util.fxdesigner.app.AbstractController
parent
-
-
Constructor Summary
Constructors Constructor Description SourceEditorController(MainDesignerController mainController)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidafterParentInit()Executed after the parent's initialization (so afterAbstractController.afterChildrenInit()).protected voidbeforeParentInit()Executed before the parent's initialization.org.reactfx.value.Var<java.util.List<net.sourceforge.pmd.lang.ast.Node>>currentErrorNodesProperty()org.reactfx.value.Var<java.util.List<net.sourceforge.pmd.lang.ast.Node>>currentRuleResultsProperty()java.lang.StringgetAuxclasspathFiles()java.util.Optional<net.sourceforge.pmd.lang.ast.Node>getCompilationUnit()Returns the most up-to-date compilation unit, or empty if it can't be parsed.java.lang.StringgetDebugName()A debug name for this component, used in developer mode to e.g.net.sourceforge.pmd.lang.LanguageVersiongetLanguageVersion()java.lang.StringgetText()org.reactfx.value.Var<net.sourceforge.pmd.lang.LanguageVersion>languageVersionProperty()java.util.Optional<net.sourceforge.pmd.lang.ast.Node>refreshAST()Refreshes the AST and returns the new compilation unit if the parse didn't fail.voidsetAuxclasspathFiles(java.lang.String files)voidsetLanguageVersion(net.sourceforge.pmd.lang.LanguageVersion version)voidsetText(java.lang.String expression)voidshowAuxclasspathSetupPopup()org.reactfx.value.Val<java.lang.String>textProperty()TextAwareNodeWrapperwrapNode(net.sourceforge.pmd.lang.ast.Node node)-
Methods inherited from class net.sourceforge.pmd.util.fxdesigner.app.AbstractController
afterChildrenInit, getChildren, getChildrenSettingsNodes, getDesignerRoot, initialize
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.sourceforge.pmd.util.fxdesigner.app.ApplicationComponent
getLogger, getMainStage, isDeveloperMode, logInternalDebugInfo, logInternalException, logMessageTrace, logUserException, raiseParsableSourceFlag, raiseParsableXPathFlag
-
-
-
-
Constructor Detail
-
SourceEditorController
public SourceEditorController(MainDesignerController mainController)
-
-
Method Detail
-
beforeParentInit
protected void beforeParentInit()
Description copied from class:AbstractControllerExecuted before the parent's initialization. Always executed once at the start of the initialization of this controller.- Overrides:
beforeParentInitin classAbstractController<MainDesignerController>
-
afterParentInit
protected void afterParentInit()
Description copied from class:AbstractControllerExecuted after the parent's initialization (so afterAbstractController.afterChildrenInit()). This also means, after persistent settings restoration. If this node has no parent, then this is never executed.- Overrides:
afterParentInitin classAbstractController<MainDesignerController>
-
refreshAST
public java.util.Optional<net.sourceforge.pmd.lang.ast.Node> refreshAST()
Refreshes the AST and returns the new compilation unit if the parse didn't fail.
-
showAuxclasspathSetupPopup
public void showAuxclasspathSetupPopup()
-
currentRuleResultsProperty
public org.reactfx.value.Var<java.util.List<net.sourceforge.pmd.lang.ast.Node>> currentRuleResultsProperty()
-
currentErrorNodesProperty
public org.reactfx.value.Var<java.util.List<net.sourceforge.pmd.lang.ast.Node>> currentErrorNodesProperty()
-
wrapNode
public TextAwareNodeWrapper wrapNode(net.sourceforge.pmd.lang.ast.Node node)
-
getLanguageVersion
public net.sourceforge.pmd.lang.LanguageVersion getLanguageVersion()
-
setLanguageVersion
public void setLanguageVersion(net.sourceforge.pmd.lang.LanguageVersion version)
-
languageVersionProperty
public org.reactfx.value.Var<net.sourceforge.pmd.lang.LanguageVersion> languageVersionProperty()
-
getCompilationUnit
public java.util.Optional<net.sourceforge.pmd.lang.ast.Node> getCompilationUnit()
Returns the most up-to-date compilation unit, or empty if it can't be parsed.
-
getText
public java.lang.String getText()
-
setText
public void setText(java.lang.String expression)
-
textProperty
public org.reactfx.value.Val<java.lang.String> textProperty()
-
getAuxclasspathFiles
public java.lang.String getAuxclasspathFiles()
-
setAuxclasspathFiles
public void setAuxclasspathFiles(java.lang.String files)
-
getDebugName
public java.lang.String getDebugName()
Description copied from interface:ApplicationComponentA debug name for this component, used in developer mode to e.g. trace events handling paths.
-
-