Enum ResponseAttributesDefaults

    • Method Detail

      • values

        public static ResponseAttributesDefaults[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (ResponseAttributesDefaults c : ResponseAttributesDefaults.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static ResponseAttributesDefaults valueOf​(java.lang.String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null
      • getTrafficControlPercentage

        public int getTrafficControlPercentage()
        Description copied from interface: ResponseAttributes
        Gets a session sampling in percent.

        Value returned here is configured per application as Cost Control.

        Specified by:
        getTrafficControlPercentage in interface ResponseAttributes
        Returns:
        traffic control/cost control percentage in range [1, 100].
      • getApplicationId

        public java.lang.String getApplicationId()
        Description copied from interface: ResponseAttributes
        Returns the ID of the application to which this configuration applies.

        This is sent by the JSON configuration only, as sanity check to fix a weird Jetty bug.

        Specified by:
        getApplicationId in interface ResponseAttributes
      • getTimestampInMilliseconds

        public long getTimestampInMilliseconds()
        Description copied from interface: ResponseAttributes
        Returns the timestamp of these attributes which were returned from the server.

        The timestamp is the duration from January, 1st, 1970

        Specified by:
        getTimestampInMilliseconds in interface ResponseAttributes
      • isAttributeSet

        public boolean isAttributeSet​(ResponseAttribute attribute)
        Description copied from interface: ResponseAttributes
        Checks whether the given attribute was set / sent from the server with this server response.
        Specified by:
        isAttributeSet in interface ResponseAttributes
        Parameters:
        attribute - the attribute to be checked if it was sent by the server.
        Returns:
        true if the given attribute was sent from the server with this attributes, false otherwise.
      • merge

        public ResponseAttributes merge​(ResponseAttributes responseAttributes)
        Description copied from interface: ResponseAttributes
        Creates a new response attributes object by merging the given response into this one. Single attributes are selectively taken over from the given attributes as long as the respective attribute is set.
        Specified by:
        merge in interface ResponseAttributes
        Parameters:
        responseAttributes - the response attributes which will be merged together with this one into a new response attributes object.
        Returns:
        a new response attributes instance by merging the given attributes with this attributes.