Class IntAnnotation

    • Constructor Detail

      • IntAnnotation

        public IntAnnotation​(int value)
        Constructor.
        Parameters:
        value - the integer value
    • Method Detail

      • clone

        public java.lang.Object clone()
        Specified by:
        clone in interface BugAnnotation
        Overrides:
        clone in class java.lang.Object
      • getValue

        public int getValue()
        Get the integer value.
        Returns:
        the integer value
      • format

        public java.lang.String format​(java.lang.String key,
                                       ClassAnnotation primaryClass)
        Description copied from interface: BugAnnotation
        Format the annotation as a String. The given key specifies additional information about how the annotation should be formatted. If the key is empty, then the "default" format will be used.
        Specified by:
        format in interface BugAnnotation
        Parameters:
        key - how the annotation should be formatted
        primaryClass - The primary class for the bug; some bug annotation format msgs are simplified in relation to that class.
      • getShortInteger

        public static java.lang.String getShortInteger​(int value)
      • getShortInteger

        public static java.lang.String getShortInteger​(long value)
      • setDescription

        public void setDescription​(java.lang.String description)
        Description copied from interface: BugAnnotation
        Set a description of this bug annotation. The description is a key for the FindBugsAnnotationDescriptions resource bundle.
        Specified by:
        setDescription in interface BugAnnotation
      • getDescription

        public java.lang.String getDescription()
        Description copied from interface: BugAnnotation
        Get a description of this bug annotation. The description is a key for the FindBugsAnnotationDescriptions resource bundle.
        Specified by:
        getDescription in interface BugAnnotation
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • compareTo

        public int compareTo​(BugAnnotation o)
        Specified by:
        compareTo in interface java.lang.Comparable<BugAnnotation>
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • writeXML

        public void writeXML​(XMLOutput xmlOutput)
                      throws java.io.IOException
        Description copied from interface: XMLWriteable
        Write this object to given XMLOutput.
        Specified by:
        writeXML in interface XMLWriteable
        Parameters:
        xmlOutput - the XMLOutput for the document
        Throws:
        java.io.IOException
      • writeXML

        public void writeXML​(XMLOutput xmlOutput,
                             boolean addMessages,
                             boolean isPrimary)
                      throws java.io.IOException
        Specified by:
        writeXML in interface XMLWriteableWithMessages
        Throws:
        java.io.IOException
      • isSignificant

        public boolean isSignificant()
        Description copied from interface: BugAnnotation
        Is this annotation used to compute instance hashes or match bug instances across versions
        Specified by:
        isSignificant in interface BugAnnotation
        Returns:
        true if significant