Class Query<ENCODES>

  • Type Parameters:
    ENCODES - The type of value represented by the query - String in the general case.
    Direct Known Subclasses:
    HttpQuery

    public class Query<ENCODES>
    extends java.lang.Object
    A query component of a URI. Immutable and thread safe.
    See Also:
    RFC 3986 - Query
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      protected Query​(ENCODES value, PercentEncodingPartial<ENCODES,​java.lang.String> percentEncodingPartial)
      Constructor for subclasses of Query with scheme specific percent encoding of characters beyond that specified for generic URI Querys.
    • Field Detail

      • STRING_QUERY_MAKING_DECODER

        public static final MakingDecoder<Query<java.lang.String>,​java.lang.String,​java.lang.String> STRING_QUERY_MAKING_DECODER
        The MakingDecoder used by standard queries.
    • Constructor Detail

      • Query

        protected Query​(ENCODES value,
                        PercentEncodingPartial<ENCODES,​java.lang.String> percentEncodingPartial)
        Constructor for subclasses of Query with scheme specific percent encoding of characters beyond that specified for generic URI Querys.
        Parameters:
        value - the (non encoded) value this object represents.
        percentEncodingPartial - the PercentEncodingPartial this subclass will use.
    • Method Detail

      • query

        public static Query<java.lang.String> query​(java.lang.String query)
        Factory method for creating Querys.
        Parameters:
        query - any String to represent as a Query.
        Returns:
        a Query representing the given String.
      • stringQueryMaker

        @Deprecated
        public static MakingDecoder<Query<java.lang.String>,​java.lang.String,​java.lang.String> stringQueryMaker()
        Deprecated.
        Factory method for MakingDecoders of String Querys.
        Returns:
        a MakingDecoder of String Querys.
      • value

        public final ENCODES value()
        Gets the (non-encoded) value of this query.
        Returns:
        the (non-encoded) value of this query.
      • equals

        public boolean equals​(java.lang.Object object)
        Overrides:
        equals in class java.lang.Object
      • hashCode

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

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