Class MsgPackDocumentIndexer

  • All Implemented Interfaces:
    MsgPackTokenVisitor

    public final class MsgPackDocumentIndexer
    extends Object
    implements MsgPackTokenVisitor
    Represents an message pack document indexer. During the indexing of an existing message pack document an MsgPackTree object will be constructed, which corresponds to the structure of the message pack document.

    Example:

    
     Say we have the following json as message pack document:
     {
       "object1":{ "field1": true, "array":[ 1,2,3]},
       "field2" : "String"
     }
     

     The #index() method will return an MsgPackTree object,
     which has the following structure:
     
              $
            /   \
       field2   object1
         |     /       \
     String  field1   array
              |      /  |  \
             true   1   2   3
     
     

    Then this correspond to the following message pack tree structure:

    NodeTypes:
     
    
     1object1 : MAP_NODE
     2field1 : LEAF
     2array : ARRAY_NODE
     1field2: LEAF
     
     
    NodeChildsMap:
     
    
     1object1: field1, array
     2array : 2array1, 2array2, 2array3,
     
     
    LeafMap:
     
    
     2field1: mapping
     2array1: mapping
     2array2: mapping
     2array3: mapping
     1field2: mapping
     
     
    • Constructor Detail

      • MsgPackDocumentIndexer

        public MsgPackDocumentIndexer()