/** * Parses a WKT PRJ String into a set of parameters. * * This is the main entry point of the parser. * * @param prjString a WKT string * @return a list of parameters * @throws PrjParserException if the PRJ cannot be parsed into a CRS for any * reason */ public Map<String, String> getParameters(String prjString) { CharBuffer s = CharBuffer.wrap(prjString); PrjElement e; try { e = parseNode(s); } catch (BufferUnderflowException ex) { throw new PrjParserException("Failed to read PRJ.", ex); } Map<String, String> prjParameters = PrjMatcher.match(e); return prjParameters; }
elms.add(parseNumber(s)); } else { elms.add(parseNode(s));