private int encodeContent(ByteBuffer buffer, int itemCount) {
        for (Iterator<Item> i = getItemIterator(); i.hasNext();) {
            Item subitem = i.next();
            itemCount += subitem.encode(buffer);
        }
        return itemCount;
    }
Returns a subitem as a word item

@param index the (0-base) index of the item to return
@throws IndexOutOfBoundsException if there is no subitem at index
container-search/src/main/java/com/yahoo/prelude/query/PhraseSegmentItem.java