Class TooltipCreator

  • All Implemented Interfaces:
    IDatatypeVisitor

    class TooltipCreator
    extends java.lang.Object
    implements IDatatypeVisitor
    Created a tooltip for a given variable. This tooltip displays the datatype of the variable, for example "Set of Compound of C".
    Author:
    El-Sharkawy
    • Field Detail

      • tooltip

        private java.lang.StringBuffer tooltip
    • Constructor Detail

      • TooltipCreator

        TooltipCreator​(IDecisionVariable variable)
        Sole constructor for this tooltip generator.
        Parameters:
        variable - The variable for which the tooltip shall be generated.
    • Method Detail

      • getTooltip

        java.lang.String getTooltip()
        Getter for the generated tooltip.
        Returns:
        Returns the datatype of the given variable as string. This can be used as a tooltip inside the GUI. This string must not be null.
      • visitSet

        public void visitSet​(Set set)
        Description copied from interface: IDatatypeVisitor
        Is called by a set data type.
        Specified by:
        visitSet in interface IDatatypeVisitor
        Parameters:
        set - the set instance
      • visitRealType

        public void visitRealType​(RealType type)
        Description copied from interface: IDatatypeVisitor
        Visiting method for visiting a RealType.
        Specified by:
        visitRealType in interface IDatatypeVisitor
        Parameters:
        type - The IDatatype which should be visited.
      • visitCompoundType

        public void visitCompoundType​(Compound compound)
        Description copied from interface: IDatatypeVisitor
        Visiting method for visiting a Compound.
        Specified by:
        visitCompoundType in interface IDatatypeVisitor
        Parameters:
        compound - The Compound which should be visited.
      • visitEnumType

        public void visitEnumType​(Enum enumType)
        Description copied from interface: IDatatypeVisitor
        Visiting method for visiting a Enum.
        Specified by:
        visitEnumType in interface IDatatypeVisitor
        Parameters:
        enumType - The Enum which should be visited.