static Set < String > parsePathParameters ( String path ) { Matcher m = PARAM_URL_REGEX . matcher ( path ) ; Set < String > patterns = new LinkedHashSet <> ( ) ; while ( m . find ( ) ) { patterns . add ( m . group ( 1 ) ) ; } return patterns ; }
Gets the set of unique path parameters used in the given URI . If a parameter is used twice in the URI it will only show up once in the set .