Class StreamingSessionIdentifier

  • All Implemented Interfaces:
    CharSequence

    public final class StreamingSessionIdentifier
    extends Object
    implements CharSequence
    Represents the identifier of a streaming session combined of a client session identifier and a server session identifier.
    Since:
    1.1.0
    • Method Detail

      • of

        public static StreamingSessionIdentifier of​(CharSequence streamingSessionIdentifier)
        Creates a new StreamingSessionIdentifier of the passed CharSequence already containing the delimiter "_-_" delimiting clientSessionId and serverSessionId.
        Parameters:
        streamingSessionIdentifier - the combined session identifier containing clientSessionId and serverSessionId.
        Returns:
        the instance.
        Throws:
        IllegalArgumentException - if the passed streamingSessionIdentifier did not contain a "_-_".
        NullPointerException - if streamingSessionIdentifier is null.
      • of

        public static StreamingSessionIdentifier of​(CharSequence clientSessionId,
                                                    CharSequence serverSessionId)
        Creates a new StreamingSessionIdentifier of the passed clientSessionId and serverSessionId.
        Parameters:
        clientSessionId - the client session identifier potentially passed by the client itself.
        serverSessionId - the server session identifier which was created by the server.
        Returns:
        the instance.
        Throws:
        NullPointerException - if any argument is null.
      • getClientSessionId

        public String getClientSessionId()
        Returns the client session identifier potentially passed by the client itself.
        Returns:
        the client session identifier potentially passed by the client itself.
      • getServerSessionId

        public String getServerSessionId()
        Returns the server session identifier which was created by the server.
        Returns:
        the server session identifier which was created by the server.
      • charAt

        public char charAt​(int index)
        Specified by:
        charAt in interface CharSequence
      • equals

        public boolean equals​(@Nullable
                              Object o)
        Overrides:
        equals in class Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object