Class ConsentMetadata


  • public class ConsentMetadata
    extends Object
    Represents metadata associated with a given consent. This class stores key-value pairs that provide additional information about the consent, such as the source or context in which the consent was provided (e.g., User-Agent, IP address).
    Author:
    nikritikos
    • Constructor Detail

      • ConsentMetadata

        public ConsentMetadata()
        Default constructor required for JAX-RS serialization/deserialization.
      • ConsentMetadata

        public ConsentMetadata​(String key,
                               String value)
        Constructs a new `ConsentMetadata` instance with the provided key and value.
        Parameters:
        key - the metadata key (e.g., "User-Agent")
        value - the metadata value (e.g., "Chrome")
    • Method Detail

      • getKey

        public String getKey()
        Gets the metadata key.
        Returns:
        the key associated with the metadata
      • setKey

        public void setKey​(String key)
        Sets the metadata key.
        Parameters:
        key - the key to set for the metadata
      • getValue

        public String getValue()
        Gets the metadata value.
        Returns:
        the value associated with the metadata
      • setValue

        public void setValue​(String value)
        Sets the metadata value.
        Parameters:
        value - the value to set for the metadata
      • toString

        public String toString()
        Returns a string representation of the metadata, showing the key and value.
        Overrides:
        toString in class Object
        Returns:
        a string representation of the metadata