Package thredds.logs

Class PathMatcher


  • public class PathMatcher
    extends Object
    Duplicate thredds.servlet.PathMatcher
    Since:
    Mar 24, 2009
    • Constructor Detail

      • PathMatcher

        public PathMatcher()
    • Method Detail

      • put

        public void put​(String root)
        Add an object to the collection to be searched by a String key.
        Parameters:
        root - sort key
      • get

        public PathMatcher.Match get​(String key)
        See if this object already exists in the collection, using equals().
        Parameters:
        key - find object that has this key
        Returns:
        existing object, else null.
      • iterator

        public Iterator iterator()
        Get an iterator over the values, in sorted order.
        Returns:
        iterator
      • match

        public PathMatcher.Match match​(String path)
        Find the longest match.
        Parameters:
        path - find object with longest match where path.startsWith( key)
        Returns:
        the value whose key is the longest that matches path, or null if none