Class AbstractComponentLocationInfo

java.lang.Object
com.vaadin.copilot.javarewriter.AbstractComponentLocationInfo
Direct Known Subclasses:
ComponentAttachInfo, ComponentCreateInfo

public abstract class AbstractComponentLocationInfo extends Object
An abstract base class that holds common information about a component extracted from Java source code during code analysis.

This class provides basic metadata for components, such as their local variable names, field declarations, and associated source information. It is intended to be extended by more specialized component information classes e.g. ComponentCreateInfo and ComponentAttachInfo

  • Field Details

    • localVariableName

      protected String localVariableName
    • localVariableDeclarator

      protected com.github.javaparser.ast.body.VariableDeclarator localVariableDeclarator
    • fieldName

      protected String fieldName
    • fieldDeclaration

      protected com.github.javaparser.ast.body.FieldDeclaration fieldDeclaration
    • fieldDeclarationAndAssignment

      protected com.github.javaparser.ast.body.FieldDeclaration fieldDeclarationAndAssignment
  • Constructor Details

    • AbstractComponentLocationInfo

      protected AbstractComponentLocationInfo(JavaSource javaSource)
      Creates a new ComponentBaseInfo with the specified Java source and file reference.
      Parameters:
      javaSource - the JavaSource representing the parsed source code where the component is defined; must not be null.
  • Method Details

    • getJavaSource

      public JavaSource getJavaSource()
    • getLocalVariableDeclarator

      public com.github.javaparser.ast.body.VariableDeclarator getLocalVariableDeclarator()
    • setLocalVariableDeclarator

      public void setLocalVariableDeclarator(com.github.javaparser.ast.body.VariableDeclarator localVariableDeclarator)
    • getFieldDeclaration

      public com.github.javaparser.ast.body.FieldDeclaration getFieldDeclaration()
    • setFieldDeclaration

      public void setFieldDeclaration(com.github.javaparser.ast.body.FieldDeclaration fieldDeclaration)
    • getLocalVariableName

      public String getLocalVariableName()
    • setLocalVariableName

      public void setLocalVariableName(String localVariableName)
    • getFieldName

      public String getFieldName()
    • setFieldName

      public void setFieldName(String fieldName)
    • getFieldDeclarationAndAssignment

      public com.github.javaparser.ast.body.FieldDeclaration getFieldDeclarationAndAssignment()
    • setFieldDeclarationAndAssignment

      public void setFieldDeclarationAndAssignment(com.github.javaparser.ast.body.FieldDeclaration fieldDeclarationAndAssignment)