Class AbstractUri<T extends NiceUri>

java.lang.Object
ch.tocco.nice2.dms.impl.uri.AbstractUri<T>
All Implemented Interfaces:
NiceUri<T>
Direct Known Subclasses:
AdminUriImpl, EntityUriImpl, PublicUriImpl

public abstract class AbstractUri<T extends NiceUri> extends Object implements NiceUri<T>
  • Field Details

    • uri

      protected final URI uri
  • Constructor Details

    • AbstractUri

      protected AbstractUri(URI uri)
  • Method Details

    • toURI

      public URI toURI()
      Description copied from interface: NiceUri
      Get the URI as URI.
      Specified by:
      toURI in interface NiceUri<T extends NiceUri>
      Returns:
      the URI as URI.
    • checkMatches

      protected void checkMatches(String stringToCheck, String pattern)
      Checks whether a string matches a regex pattern and throws an IllegalArgumentException if it doesn't.
      Parameters:
      stringToCheck - the string to check.
      pattern - the pattern.
    • withQuery

      protected static URI withQuery(URI uri, String query)
    • withFragment

      protected static URI withFragment(URI uri, String fragment)
    • withQueryAndFragment

      protected static URI withQueryAndFragment(URI uri, String query, String fragment)