Package hudson.model

Class UpdateSite.Warning

    • Field Detail

      • id

        @Exported
        @NonNull
        public final String id
        The globally unique ID of this warning.

        This is typically the CVE identifier or SECURITY issue (Jenkins project); possibly with a unique suffix (e.g. artifactId) if either applies to multiple components.

      • component

        @Exported
        @NonNull
        public final String component
        The name of the affected component.
        • If type is 'core', this is 'core' by convention.
        • If type is 'plugin', this is the artifactId of the affected plugin
      • message

        @Exported
        @NonNull
        public final String message
        A short, English language explanation for this warning.
      • url

        @Exported
        @NonNull
        public final String url
        A URL with more information about this, typically a security advisory. For use in administrator notices only, so
      • versionRanges

        @Exported
        @NonNull
        public final List<UpdateSite.WarningVersionRange> versionRanges
        A list of named version ranges specifying which versions of the named component this warning applies to. If this list is empty, all versions of the component are considered to be affected by this warning.
    • Constructor Detail

      • Warning

        @Restricted(org.kohsuke.accmod.restrictions.NoExternalUse.class)
        public Warning​(net.sf.json.JSONObject o)
        Parameters:
        o - the JSONObject representing the warning
        Throws:
        net.sf.json.JSONException - if the argument does not match the expected format
    • Method Detail

      • equals

        public boolean equals​(Object o)
        Two objects are considered equal if they are the same type and have the same ID.
        Overrides:
        equals in class Object
        Parameters:
        o - the other object
        Returns:
        true iff this object and the argument are considered equal
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object
      • isPluginWarning

        public boolean isPluginWarning​(@NonNull
                                       String pluginName)
      • isRelevant

        public boolean isRelevant()
        Returns true if this warning is relevant to the current configuration
        Returns:
        true if this warning is relevant to the current configuration
      • isRelevantToVersion

        public boolean isRelevantToVersion​(@NonNull
                                           VersionNumber version)