MCPcopy Create free account
hub / github.com/apache/solr / isUnquotedStringChar

Method isUnquotedStringChar

solr/solrj/src/java/org/noggit/JSONParser.java:823–846  ·  view source on GitHub ↗
(int ch)

Source from the content-addressed store, hash-verified

821 // What characters are allowed to continue an unquoted string
822 // once we know we are in one.
823 private static boolean isUnquotedStringChar(int ch) {
824 return Character.isJavaIdentifierPart(ch) || ch == '.' || ch == '-' || ch == '/';
825
826 // would checking for a-z first speed up the common case?
827
828 // possibly much more liberal unquoted string handling...
829 /*
830 switch (ch) {
831 case -1:
832 case ' ':
833 case '\t':
834 case '\r':
835 case '\n':
836 case '}':
837 case ']':
838 case ',':
839 case ':':
840 case '=': // reserved for future use
841 case '\\': // check for backslash should come after this function call
842 return false;
843 }
844 return true;
845 */
846 }
847
848 /* alternate implementation
849 // middle is the pointer to the middle of a buffer to start scanning for a non-string

Callers 2

matchBareWordMethod · 0.95
readStringBareMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected