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. TheNodeEditionCodeArea
handles 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 void
afterParentInit()
Executed after the parent's initialization (so afterAbstractController.afterChildrenInit()
).protected void
beforeParentInit()
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.String
getAuxclasspathFiles()
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.String
getDebugName()
A debug name for this component, used in developer mode to e.g.net.sourceforge.pmd.lang.LanguageVersion
getLanguageVersion()
java.lang.String
getText()
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.void
setAuxclasspathFiles(java.lang.String files)
void
setLanguageVersion(net.sourceforge.pmd.lang.LanguageVersion version)
void
setText(java.lang.String expression)
void
showAuxclasspathSetupPopup()
org.reactfx.value.Val<java.lang.String>
textProperty()
TextAwareNodeWrapper
wrapNode(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:AbstractController
Executed before the parent's initialization. Always executed once at the start of the initialization of this controller.- Overrides:
beforeParentInit
in classAbstractController<MainDesignerController>
-
afterParentInit
protected void afterParentInit()
Description copied from class:AbstractController
Executed 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:
afterParentInit
in 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:ApplicationComponent
A debug name for this component, used in developer mode to e.g. trace events handling paths.
-
-