Package com.fasterxml.jackson.core.sym

Examples of com.fasterxml.jackson.core.sym.Name


            return JsonToken.FIELD_NAME;
        case 2: // short ASCII
      {
          int len = 1 + (ch & 0x3f);
          String name;
          Name n = _findDecodedFromSymbols(len);
          if (n != null) {
              name = n.getName();
              _inputPtr += len;
          } else {
              name = _decodeShortAsciiName(len);
              name = _addDecodedToSymbols(len, name);
          }
                if (_seenNames != null) {
                   if (_seenNameCount >= _seenNames.length) {
                    _seenNames = _expandSeenNames(_seenNames);
                   }
                   _seenNames[_seenNameCount++] = name;
                }
                _parsingContext.setCurrentName(name);
      }
      return JsonToken.FIELD_NAME;               
        case 3: // short Unicode
            // all valid, except for 0xFF
            ch &= 0x3F;
            {
                if (ch > 0x37) {
                    if (ch == 0x3B) {
                        if (!_parsingContext.inObject()) {
                            _reportMismatchedEndMarker('}', ']');
                        }
                        _parsingContext = _parsingContext.getParent();
                        return JsonToken.END_OBJECT;
                    }
                } else {
                    final int len = ch + 2; // values from 2 to 57...
                    String name;
                    Name n = _findDecodedFromSymbols(len);
                    if (n != null) {
                        name = n.getName();
                        _inputPtr += len;
                    } else {
                        name = _decodeShortUnicodeName(len);
                        name = _addDecodedToSymbols(len, name);
                    }
View Full Code Here


            byteLen += bytes;
        }
       
        // Know this name already?
        String name;
        Name n = _symbols.findName(_quadBuffer, quads);
        if (n != null) {
            name = n.getName();
        } else {
            name = _decodeLongUnicodeName(_quadBuffer, byteLen, quads).getName();
        }
        if (_seenNames != null) {
           if (_seenNameCount >= _seenNames.length) {
View Full Code Here

            return JsonToken.FIELD_NAME;
        case 2: // short ASCII
      {
          int len = 1 + (ch & 0x3f);
          String name;
          Name n = _findDecodedFromSymbols(len);
          if (n != null) {
              name = n.getName();
              _inputPtr += len;
          } else {
              name = _decodeShortAsciiName(len);
              name = _addDecodedToSymbols(len, name);
          }
                if (_seenNames != null) {
                   if (_seenNameCount >= _seenNames.length) {
                    _seenNames = _expandSeenNames(_seenNames);
                   }
                   _seenNames[_seenNameCount++] = name;
                }
                _parsingContext.setCurrentName(name);
      }
      return JsonToken.FIELD_NAME;               
        case 3: // short Unicode
            // all valid, except for 0xFF
            ch &= 0x3F;
            {
                if (ch > 0x37) {
                    if (ch == 0x3B) {
                        if (!_parsingContext.inObject()) {
                            _reportMismatchedEndMarker('}', ']');
                        }
                        _parsingContext = _parsingContext.getParent();
                        return JsonToken.END_OBJECT;
                    }
                } else {
                    final int len = ch + 2; // values from 2 to 57...
                    String name;
                    Name n = _findDecodedFromSymbols(len);
                    if (n != null) {
                        name = n.getName();
                        _inputPtr += len;
                    } else {
                        name = _decodeShortUnicodeName(len);
                        name = _addDecodedToSymbols(len, name);
                    }
View Full Code Here

            byteLen += bytes;
        }
       
        // Know this name already?
        String name;
        Name n = _symbols.findName(_quadBuffer, quads);
        if (n != null) {
            name = n.getName();
        } else {
            name = _decodeLongUnicodeName(_quadBuffer, byteLen, quads).getName();
        }
        if (_seenNames != null) {
           if (_seenNameCount >= _seenNames.length) {
View Full Code Here

            return JsonToken.FIELD_NAME;
        case 2: // short ASCII
            {
                int len = 1 + (ch & 0x3f);
                String name;
                Name n = _findDecodedFromSymbols(len);
                if (n != null) {
                    name = n.getName();
                    _inputPtr += len;
                } else {
                    name = _decodeShortAsciiName(len);
                    name = _addDecodedToSymbols(len, name);
                }
                if (_seenNames != null) {
                    if (_seenNameCount >= _seenNames.length) {
                        _seenNames = _expandSeenNames(_seenNames);
                    }
                    _seenNames[_seenNameCount++] = name;
                }
                _parsingContext.setCurrentName(name);
            }
            return JsonToken.FIELD_NAME;               
        case 3: // short Unicode
            // all valid, except for 0xFF
            ch &= 0x3F;
            {
                if (ch > 0x37) {
                    if (ch == 0x3B) {
                        if (!_parsingContext.inObject()) {
                            _reportMismatchedEndMarker('}', ']');
                        }
                        _parsingContext = _parsingContext.getParent();
                        return JsonToken.END_OBJECT;
                    }
                } else {
                    final int len = ch + 2; // values from 2 to 57...
                    String name;
                    Name n = _findDecodedFromSymbols(len);
                    if (n != null) {
                        name = n.getName();
                        _inputPtr += len;
                    } else {
                        name = _decodeShortUnicodeName(len);
                        name = _addDecodedToSymbols(len, name);
                    }
View Full Code Here

            byteLen += bytes;
        }
       
        // Know this name already?
        String name;
        Name n = _symbols.findName(_quadBuffer, quads);
        if (n != null) {
            name = n.getName();
        } else {
            name = _decodeLongUnicodeName(_quadBuffer, byteLen, quads).getName();
        }
        if (_seenNames != null) {
           if (_seenNameCount >= _seenNames.length) {
View Full Code Here

                .makeChild(JsonFactory.Feature.collectDefaults());
        assertNull(nc.findName(A_BYTES));
        assertNull(nc.findName(A_BYTES, B_BYTES));

        nc.addName("AAAA", new int[] { A_BYTES }, 1);
        Name n1 = nc.findName(A_BYTES);
        assertNotNull(n1);
        assertEquals("AAAA", n1.getName());
        nc.addName("AAAABBBB", new int[] { A_BYTES, B_BYTES }, 2);
        Name n2 = nc.findName(A_BYTES, B_BYTES);
        assertEquals("AAAABBBB", n2.getName());
        assertNotNull(n2);

        /* and let's then just exercise this method so it gets covered;
         * it's only used for debugging.
         */
 
View Full Code Here

            return JsonToken.FIELD_NAME;
        case 2: // short ASCII
      {
          int len = 1 + (ch & 0x3f);
          String name;
          Name n = _findDecodedFromSymbols(len);
          if (n != null) {
              name = n.getName();
              _inputPtr += len;
          } else {
              name = _decodeShortAsciiName(len);
              name = _addDecodedToSymbols(len, name);
          }
                if (_seenNames != null) {
                   if (_seenNameCount >= _seenNames.length) {
                    _seenNames = _expandSeenNames(_seenNames);
                   }
                   _seenNames[_seenNameCount++] = name;
                }
                _parsingContext.setCurrentName(name);
      }
      return JsonToken.FIELD_NAME;               
        case 3: // short Unicode
            // all valid, except for 0xFF
            ch &= 0x3F;
            {
                if (ch > 0x37) {
                    if (ch == 0x3B) {
                        if (!_parsingContext.inObject()) {
                            _reportMismatchedEndMarker('}', ']');
                        }
                        _parsingContext = _parsingContext.getParent();
                        return JsonToken.END_OBJECT;
                    }
                } else {
                    final int len = ch + 2; // values from 2 to 57...
                    String name;
                    Name n = _findDecodedFromSymbols(len);
                    if (n != null) {
                        name = n.getName();
                        _inputPtr += len;
                    } else {
                        name = _decodeShortUnicodeName(len);
                        name = _addDecodedToSymbols(len, name);
                    }
View Full Code Here

            byteLen += bytes;
        }
       
        // Know this name already?
        String name;
        Name n = _symbols.findName(_quadBuffer, quads);
        if (n != null) {
            name = n.getName();
        } else {
            name = _decodeLongUnicodeName(_quadBuffer, byteLen, quads).getName();
        }
        if (_seenNames != null) {
           if (_seenNameCount >= _seenNames.length) {
View Full Code Here

            return JsonToken.FIELD_NAME;
        case 2: // short ASCII
      {
          int len = 1 + (ch & 0x3f);
          String name;
          Name n = _findDecodedFromSymbols(len);
          if (n != null) {
              name = n.getName();
              _inputPtr += len;
          } else {
              name = _decodeShortAsciiName(len);
              name = _addDecodedToSymbols(len, name);
          }
                if (_seenNames != null) {
                   if (_seenNameCount >= _seenNames.length) {
                    _seenNames = _expandSeenNames(_seenNames);
                   }
                   _seenNames[_seenNameCount++] = name;
                }
                _parsingContext.setCurrentName(name);
      }
      return JsonToken.FIELD_NAME;               
        case 3: // short Unicode
            // all valid, except for 0xFF
            ch &= 0x3F;
            {
                if (ch > 0x37) {
                    if (ch == 0x3B) {
                        if (!_parsingContext.inObject()) {
                            _reportMismatchedEndMarker('}', ']');
                        }
                        _parsingContext = _parsingContext.getParent();
                        return JsonToken.END_OBJECT;
                    }
                } else {
                    final int len = ch + 2; // values from 2 to 57...
                    String name;
                    Name n = _findDecodedFromSymbols(len);
                    if (n != null) {
                        name = n.getName();
                        _inputPtr += len;
                    } else {
                        name = _decodeShortUnicodeName(len);
                        name = _addDecodedToSymbols(len, name);
                    }
View Full Code Here

TOP

Related Classes of com.fasterxml.jackson.core.sym.Name

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.