Class Rule


  • public class Rule
    extends Object
    Java Bean class representing a Checkstyle rule.
    Author:
    Ullrich Hafner
    • Constructor Detail

      • Rule

        public Rule()
        Instantiates a new rule.
      • Rule

        public Rule​(@CheckForNull
                    String name)
        Instantiates a new rule.
        Parameters:
        name - the name of the rule
    • Method Detail

      • getName

        public String getName()
        Returns the name of this rule.
        Returns:
        the name
      • setName

        public void setName​(@CheckForNull
                            String name)
        Sets the name of this rule.
        Parameters:
        name - the name
      • getDescription

        public String getDescription()
        Returns the description of this rule.
        Returns:
        the description
      • setDescription

        public void setDescription​(Topic topic)
        Sets the description of this rule. The description is only set if the topic is a description.
        Parameters:
        topic - the topic that might contain the description