MCPcopy Create free account
hub / github.com/SeleniumHQ/selenium / parseValue

Method parseValue

java/src/org/openqa/selenium/grid/graphql/Types.java:55–74  ·  view source on GitHub ↗
(Object input)

Source from the content-addressed store, hash-verified

53 }
54
55 @Override
56 public URI parseValue(Object input) throws CoercingParseValueException {
57 if (input instanceof URI) {
58 return (URI) input;
59 }
60
61 try {
62 if (input instanceof String) {
63 return new URI((String) input);
64 }
65
66 if (input instanceof URL) {
67 return ((URL) input).toURI();
68 }
69 } catch (URISyntaxException e) {
70 throw new CoercingParseValueException("Unable to create URI: " + input, e);
71 }
72
73 throw new CoercingParseValueException("Unable to create URI: " + input);
74 }
75
76 @Override
77 public URI parseLiteral(Object input) throws CoercingParseLiteralException {

Callers

nothing calls this directly

Calls 1

toURLMethod · 0.45

Tested by

no test coverage detected