Class Package

  • All Implemented Interfaces:
    java.io.Serializable

    public class Package
    extends java.lang.Object
    implements java.io.Serializable
    Package encapsulating addresses eligible to have SNMP data collected from them.
    See Also:
    Serialized Form
    • Constructor Detail

      • Package

        public Package()
      • Package

        public Package​(Package pkg)
        Copy constructor.
        Parameters:
        pkg -
    • Method Detail

      • getName

        public java.lang.String getName()
        The name or identifier for this package
      • setName

        public void setName​(java.lang.String name)
      • getFilter

        public Filter getFilter()
        A rule which addresses belonging to this package must pass. This package is applied only to addresses that pass this filter.
      • setFilter

        public void setFilter​(Filter filter)
      • getSpecifics

        public java.util.List<java.lang.String> getSpecifics()
      • setSpecifics

        public void setSpecifics​(java.util.List<java.lang.String> specifics)
      • addSpecific

        public void addSpecific​(java.lang.String specific)
                         throws java.lang.IndexOutOfBoundsException
        Throws:
        java.lang.IndexOutOfBoundsException
      • removeSpecific

        public boolean removeSpecific​(java.lang.String specific)
      • hasSpecific

        public boolean hasSpecific​(byte[] addr)
      • getIncludeRanges

        public java.util.List<IncludeRange> getIncludeRanges()
      • setIncludeRanges

        public void setIncludeRanges​(java.util.List<IncludeRange> ranges)
      • addIncludeRange

        public void addIncludeRange​(IncludeRange range)
                             throws java.lang.IndexOutOfBoundsException
        Throws:
        java.lang.IndexOutOfBoundsException
      • removeIncludeRange

        public boolean removeIncludeRange​(IncludeRange range)
      • hasIncludeRange

        public boolean hasIncludeRange​(java.lang.String addr)
      • getExcludeRanges

        public java.util.List<ExcludeRange> getExcludeRanges()
      • setExcludeRanges

        public void setExcludeRanges​(java.util.List<ExcludeRange> ranges)
      • addExcludeRange

        public void addExcludeRange​(ExcludeRange range)
                             throws java.lang.IndexOutOfBoundsException
        Throws:
        java.lang.IndexOutOfBoundsException
      • removeExcludeRange

        public boolean removeExcludeRange​(ExcludeRange range)
      • hasExcludeRange

        public boolean hasExcludeRange​(java.lang.String addr)
      • getIncludeUrls

        public java.util.List<java.lang.String> getIncludeUrls()
      • setIncludeUrlCollection

        public void setIncludeUrlCollection​(java.util.List<java.lang.String> urls)
      • addIncludeUrl

        public void addIncludeUrl​(java.lang.String url)
                           throws java.lang.IndexOutOfBoundsException
        Throws:
        java.lang.IndexOutOfBoundsException
      • removeIncludeUrl

        public boolean removeIncludeUrl​(java.lang.String url)
      • hasSpecificUrl

        public boolean hasSpecificUrl​(java.lang.String iface,
                                      boolean hasSpecific)
      • getStoreByIfAlias

        public java.lang.String getStoreByIfAlias()
        Flag for storing collected data by domain/ifAlias. Defaults to false. Allowable values are true, false.
      • setStoreByIfAlias

        public void setStoreByIfAlias​(java.lang.String storeByIfAlias)
      • getStoreByNodeID

        public java.lang.String getStoreByNodeID()
        Flag for storing collected data by nodeid/interface name. Defaults to normal. Allowable values are true, false, normal.
      • setStoreByNodeID

        public void setStoreByNodeID​(java.lang.String storeByNodeID)
      • getStorFlagOverride

        public java.lang.String getStorFlagOverride()
        RFlag for controlling how interfaces are selected for data collection by domain/ifAlias. If true, storage will occur for any interface on the node found to have an valid ifAlias. Otherwise data will be stored only if the interface is configured for data collection. Defaults to false.
      • setStorFlagOverride

        public void setStorFlagOverride​(java.lang.String storFlagOverride)
      • getIfAliasDomain

        public java.lang.String getIfAliasDomain()
        The name of the domain covered by this collection package. Defaults to package name.
      • setIfAliasDomain

        public void setIfAliasDomain​(java.lang.String ifAliasDomain)
      • getIfAliasComment

        public java.lang.String getIfAliasComment()
        A character or string for terminating ifAlias text. In effect, any text beginning with this character or string becomes a comment and is not considered part of the ifAlias when naming storage files and displaying data. Defaults to null.
      • setIfAliasComment

        public void setIfAliasComment​(java.lang.String ifAliasComment)
      • getServices

        public java.util.List<Service> getServices()
      • setServices

        public void setServices​(java.util.List<Service> services)
      • addService

        public void addService​(Service service)
                        throws java.lang.IndexOutOfBoundsException
        Throws:
        java.lang.IndexOutOfBoundsException
      • removeService

        public boolean removeService​(Service service)
      • getService

        public Service getService​(java.lang.String svcName)
      • serviceInPackageAndEnabled

        public boolean serviceInPackageAndEnabled​(java.lang.String svcName)
        Returns true if the service is part of the package and the status of the service is set to "on". Returns false if the service is not in the package or it is but the status of the service is set to "off".
        Parameters:
        svcName - The service name to lookup.
        Returns:
        a boolean.
      • getOutageCalendars

        public java.util.List<java.lang.String> getOutageCalendars()
      • setOutageCalendars

        public void setOutageCalendars​(java.util.List<java.lang.String> calendars)
      • addOutageCalendar

        public void addOutageCalendar​(java.lang.String calendar)
                               throws java.lang.IndexOutOfBoundsException
        Throws:
        java.lang.IndexOutOfBoundsException
      • removeOutageCalendar

        public boolean removeOutageCalendar​(java.lang.String calendar)
      • hashCode

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

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object
      • isRemote

        public boolean isRemote()
      • setRemote

        public void setRemote​(boolean remote)
      • toString

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