Interface HeaderManager

    • Method Detail

      • discoverSupportedHeaders

        AsyncResult<List<String>> discoverSupportedHeaders​(Jid jid)
        Discovers the supported headers of another entity.
        Parameters:
        jid - The JID.
        Returns:
        The async result with the list of supported headers.
      • getSupportedHeaders

        Set<String> getSupportedHeaders()
        Gets the supported headers as unmodifiable set.

        If you want to advertise support for a specific header, add it to this set. Service discovery requests to the 'header' node will then reveal supported headers.

        Returns:
        The supported headers.
      • addSupportedHeader

        boolean addSupportedHeader​(String header)
        Adds a supported header. Adding a header automatically includes this protocol in service discovery responses.
        Parameters:
        header - The header.
        Returns:
        True, if the header was added.
        See Also:
        removeSupportedHeader(String)
      • removeSupportedHeader

        boolean removeSupportedHeader​(String header)
        Removes a supported header. If there are no headers left, this protocol is no longer included in service discovery responses.
        Parameters:
        header - The header.
        Returns:
        True, if the header was removed.
        See Also:
        addSupportedHeader(String)