Java Code Examples for com.sun.xml.internal.fastinfoset.util.StringArray

The following examples show how to use com.sun.xml.internal.fastinfoset.util.StringArray. These examples are extracted from open source projects. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
/** Creates a new instance of ParserVocabulary */
public ParserVocabulary() {
    namespaceName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    prefix = new PrefixArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);
    localName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    otherNCName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    otherURI = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, true);
    attributeValue = new StringArray(ValueArray.DEFAULT_CAPACITY, NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, true);
    otherString = new CharArrayArray(ValueArray.DEFAULT_CAPACITY, NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);

    characterContentChunk = new ContiguousCharArrayArray(ValueArray.DEFAULT_CAPACITY,
            NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS,
            ContiguousCharArrayArray.INITIAL_CHARACTER_SIZE,
            NON_IDENTIFYING_STRING_TABLE_MAXIMUM_CHARACTERS);

    elementName = new QualifiedNameArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);
    attributeName = new QualifiedNameArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);

    tables[RESTRICTED_ALPHABET] = restrictedAlphabet;
    tables[ENCODING_ALGORITHM] = encodingAlgorithm;
    tables[PREFIX] = prefix;
    tables[NAMESPACE_NAME] = namespaceName;
    tables[LOCAL_NAME] = localName;
    tables[OTHER_NCNAME] = otherNCName;
    tables[OTHER_URI] = otherURI;
    tables[ATTRIBUTE_VALUE] = attributeValue;
    tables[OTHER_STRING] = otherString;
    tables[CHARACTER_CONTENT_CHUNK] = characterContentChunk;
    tables[ELEMENT_NAME] = elementName;
    tables[ATTRIBUTE_NAME] = attributeName;
}
 
Example 2
private void addToTable(String s, StringArray a, StringIntMap m) {
    if (s.length() == 0) {
        return;
    }

    if (m != null) m.obtainIndex(s);
    a.add(s);
}
 
Example 3
Source Project: TencentKona-8   Source File: Decoder.java    License: GNU General Public License v2.0 5 votes vote down vote up
private void decodeTableItems(StringArray array) throws FastInfosetException, IOException {
    final int noOfItems = decodeNumberOfItemsOfSequence();

    for (int i = 0; i < noOfItems; i++) {
        array.add(decodeNonEmptyOctetStringOnSecondBitAsUtf8String());
    }
}
 
Example 4
public void addToTable(String s, Set v, StringIntMap m, StringArray a) {
    if (s.length() == 0) {
        return;
    }

    if (m.obtainIndex(s) == KeyIntMap.NOT_PRESENT) {
        a.add(s);
    }

    v.add(s);
}
 
Example 5
Source Project: TencentKona-8   Source File: PrintTable.java    License: GNU General Public License v2.0 5 votes vote down vote up
public static void printArray(String title, StringArray a) {
    System.out.println(title);

    for (int i = 0; i < a.getSize(); i++) {
        System.out.println("" + (i + 1) + ": " + a.getArray()[i]);
    }
}
 
Example 6
Source Project: jdk8u60   Source File: ParserVocabulary.java    License: GNU General Public License v2.0 5 votes vote down vote up
/** Creates a new instance of ParserVocabulary */
public ParserVocabulary() {
    namespaceName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    prefix = new PrefixArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);
    localName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    otherNCName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    otherURI = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, true);
    attributeValue = new StringArray(ValueArray.DEFAULT_CAPACITY, NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, true);
    otherString = new CharArrayArray(ValueArray.DEFAULT_CAPACITY, NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);

    characterContentChunk = new ContiguousCharArrayArray(ValueArray.DEFAULT_CAPACITY,
            NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS,
            ContiguousCharArrayArray.INITIAL_CHARACTER_SIZE,
            NON_IDENTIFYING_STRING_TABLE_MAXIMUM_CHARACTERS);

    elementName = new QualifiedNameArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);
    attributeName = new QualifiedNameArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);

    tables[RESTRICTED_ALPHABET] = restrictedAlphabet;
    tables[ENCODING_ALGORITHM] = encodingAlgorithm;
    tables[PREFIX] = prefix;
    tables[NAMESPACE_NAME] = namespaceName;
    tables[LOCAL_NAME] = localName;
    tables[OTHER_NCNAME] = otherNCName;
    tables[OTHER_URI] = otherURI;
    tables[ATTRIBUTE_VALUE] = attributeValue;
    tables[OTHER_STRING] = otherString;
    tables[CHARACTER_CONTENT_CHUNK] = characterContentChunk;
    tables[ELEMENT_NAME] = elementName;
    tables[ATTRIBUTE_NAME] = attributeName;
}
 
Example 7
Source Project: jdk8u60   Source File: ParserVocabulary.java    License: GNU General Public License v2.0 5 votes vote down vote up
private void addToTable(String s, StringArray a, StringIntMap m) {
    if (s.length() == 0) {
        return;
    }

    if (m != null) m.obtainIndex(s);
    a.add(s);
}
 
Example 8
Source Project: jdk8u60   Source File: Decoder.java    License: GNU General Public License v2.0 5 votes vote down vote up
private void decodeTableItems(StringArray array) throws FastInfosetException, IOException {
    final int noOfItems = decodeNumberOfItemsOfSequence();

    for (int i = 0; i < noOfItems; i++) {
        array.add(decodeNonEmptyOctetStringOnSecondBitAsUtf8String());
    }
}
 
Example 9
Source Project: jdk8u60   Source File: VocabularyGenerator.java    License: GNU General Public License v2.0 5 votes vote down vote up
public void addToTable(String s, Set v, StringIntMap m, StringArray a) {
    if (s.length() == 0) {
        return;
    }

    if (m.obtainIndex(s) == KeyIntMap.NOT_PRESENT) {
        a.add(s);
    }

    v.add(s);
}
 
Example 10
Source Project: jdk8u60   Source File: PrintTable.java    License: GNU General Public License v2.0 5 votes vote down vote up
public static void printArray(String title, StringArray a) {
    System.out.println(title);

    for (int i = 0; i < a.getSize(); i++) {
        System.out.println("" + (i + 1) + ": " + a.getArray()[i]);
    }
}
 
Example 11
/** Creates a new instance of ParserVocabulary */
public ParserVocabulary() {
    namespaceName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    prefix = new PrefixArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);
    localName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    otherNCName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    otherURI = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, true);
    attributeValue = new StringArray(ValueArray.DEFAULT_CAPACITY, NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, true);
    otherString = new CharArrayArray(ValueArray.DEFAULT_CAPACITY, NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);

    characterContentChunk = new ContiguousCharArrayArray(ValueArray.DEFAULT_CAPACITY,
            NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS,
            ContiguousCharArrayArray.INITIAL_CHARACTER_SIZE,
            NON_IDENTIFYING_STRING_TABLE_MAXIMUM_CHARACTERS);

    elementName = new QualifiedNameArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);
    attributeName = new QualifiedNameArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);

    tables[RESTRICTED_ALPHABET] = restrictedAlphabet;
    tables[ENCODING_ALGORITHM] = encodingAlgorithm;
    tables[PREFIX] = prefix;
    tables[NAMESPACE_NAME] = namespaceName;
    tables[LOCAL_NAME] = localName;
    tables[OTHER_NCNAME] = otherNCName;
    tables[OTHER_URI] = otherURI;
    tables[ATTRIBUTE_VALUE] = attributeValue;
    tables[OTHER_STRING] = otherString;
    tables[CHARACTER_CONTENT_CHUNK] = characterContentChunk;
    tables[ELEMENT_NAME] = elementName;
    tables[ATTRIBUTE_NAME] = attributeName;
}
 
Example 12
private void addToTable(String s, StringArray a, StringIntMap m) {
    if (s.length() == 0) {
        return;
    }

    if (m != null) m.obtainIndex(s);
    a.add(s);
}
 
Example 13
Source Project: openjdk-jdk8u   Source File: Decoder.java    License: GNU General Public License v2.0 5 votes vote down vote up
private void decodeTableItems(StringArray array) throws FastInfosetException, IOException {
    final int noOfItems = decodeNumberOfItemsOfSequence();

    for (int i = 0; i < noOfItems; i++) {
        array.add(decodeNonEmptyOctetStringOnSecondBitAsUtf8String());
    }
}
 
Example 14
public void addToTable(String s, Set v, StringIntMap m, StringArray a) {
    if (s.length() == 0) {
        return;
    }

    if (m.obtainIndex(s) == KeyIntMap.NOT_PRESENT) {
        a.add(s);
    }

    v.add(s);
}
 
Example 15
Source Project: openjdk-jdk8u   Source File: PrintTable.java    License: GNU General Public License v2.0 5 votes vote down vote up
public static void printArray(String title, StringArray a) {
    System.out.println(title);

    for (int i = 0; i < a.getSize(); i++) {
        System.out.println("" + (i + 1) + ": " + a.getArray()[i]);
    }
}
 
Example 16
/** Creates a new instance of ParserVocabulary */
public ParserVocabulary() {
    namespaceName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    prefix = new PrefixArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);
    localName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    otherNCName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    otherURI = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, true);
    attributeValue = new StringArray(ValueArray.DEFAULT_CAPACITY, NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, true);
    otherString = new CharArrayArray(ValueArray.DEFAULT_CAPACITY, NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);

    characterContentChunk = new ContiguousCharArrayArray(ValueArray.DEFAULT_CAPACITY,
            NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS,
            ContiguousCharArrayArray.INITIAL_CHARACTER_SIZE,
            NON_IDENTIFYING_STRING_TABLE_MAXIMUM_CHARACTERS);

    elementName = new QualifiedNameArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);
    attributeName = new QualifiedNameArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);

    tables[RESTRICTED_ALPHABET] = restrictedAlphabet;
    tables[ENCODING_ALGORITHM] = encodingAlgorithm;
    tables[PREFIX] = prefix;
    tables[NAMESPACE_NAME] = namespaceName;
    tables[LOCAL_NAME] = localName;
    tables[OTHER_NCNAME] = otherNCName;
    tables[OTHER_URI] = otherURI;
    tables[ATTRIBUTE_VALUE] = attributeValue;
    tables[OTHER_STRING] = otherString;
    tables[CHARACTER_CONTENT_CHUNK] = characterContentChunk;
    tables[ELEMENT_NAME] = elementName;
    tables[ATTRIBUTE_NAME] = attributeName;
}
 
Example 17
private void addToTable(String s, StringArray a, StringIntMap m) {
    if (s.length() == 0) {
        return;
    }

    if (m != null) m.obtainIndex(s);
    a.add(s);
}
 
Example 18
Source Project: openjdk-jdk8u-backup   Source File: Decoder.java    License: GNU General Public License v2.0 5 votes vote down vote up
private void decodeTableItems(StringArray array) throws FastInfosetException, IOException {
    final int noOfItems = decodeNumberOfItemsOfSequence();

    for (int i = 0; i < noOfItems; i++) {
        array.add(decodeNonEmptyOctetStringOnSecondBitAsUtf8String());
    }
}
 
Example 19
public void addToTable(String s, Set v, StringIntMap m, StringArray a) {
    if (s.length() == 0) {
        return;
    }

    if (m.obtainIndex(s) == KeyIntMap.NOT_PRESENT) {
        a.add(s);
    }

    v.add(s);
}
 
Example 20
public static void printArray(String title, StringArray a) {
    System.out.println(title);

    for (int i = 0; i < a.getSize(); i++) {
        System.out.println("" + (i + 1) + ": " + a.getArray()[i]);
    }
}
 
Example 21
/** Creates a new instance of ParserVocabulary */
public ParserVocabulary() {
    namespaceName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    prefix = new PrefixArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);
    localName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    otherNCName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    otherURI = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, true);
    attributeValue = new StringArray(ValueArray.DEFAULT_CAPACITY, NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, true);
    otherString = new CharArrayArray(ValueArray.DEFAULT_CAPACITY, NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);

    characterContentChunk = new ContiguousCharArrayArray(ValueArray.DEFAULT_CAPACITY,
            NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS,
            ContiguousCharArrayArray.INITIAL_CHARACTER_SIZE,
            NON_IDENTIFYING_STRING_TABLE_MAXIMUM_CHARACTERS);

    elementName = new QualifiedNameArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);
    attributeName = new QualifiedNameArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);

    tables[RESTRICTED_ALPHABET] = restrictedAlphabet;
    tables[ENCODING_ALGORITHM] = encodingAlgorithm;
    tables[PREFIX] = prefix;
    tables[NAMESPACE_NAME] = namespaceName;
    tables[LOCAL_NAME] = localName;
    tables[OTHER_NCNAME] = otherNCName;
    tables[OTHER_URI] = otherURI;
    tables[ATTRIBUTE_VALUE] = attributeValue;
    tables[OTHER_STRING] = otherString;
    tables[CHARACTER_CONTENT_CHUNK] = characterContentChunk;
    tables[ELEMENT_NAME] = elementName;
    tables[ATTRIBUTE_NAME] = attributeName;
}
 
Example 22
private void addToTable(String s, StringArray a, StringIntMap m) {
    if (s.length() == 0) {
        return;
    }

    if (m != null) m.obtainIndex(s);
    a.add(s);
}
 
Example 23
Source Project: openjdk-jdk9   Source File: Decoder.java    License: GNU General Public License v2.0 5 votes vote down vote up
private void decodeTableItems(StringArray array) throws FastInfosetException, IOException {
    final int noOfItems = decodeNumberOfItemsOfSequence();

    for (int i = 0; i < noOfItems; i++) {
        array.add(decodeNonEmptyOctetStringOnSecondBitAsUtf8String());
    }
}
 
Example 24
public void addToTable(String s, Set v, StringIntMap m, StringArray a) {
    if (s.length() == 0) {
        return;
    }

    if (m.obtainIndex(s) == KeyIntMap.NOT_PRESENT) {
        a.add(s);
    }

    v.add(s);
}
 
Example 25
Source Project: openjdk-jdk9   Source File: PrintTable.java    License: GNU General Public License v2.0 5 votes vote down vote up
public static void printArray(String title, StringArray a) {
    System.out.println(title);

    for (int i = 0; i < a.getSize(); i++) {
        System.out.println("" + (i + 1) + ": " + a.getArray()[i]);
    }
}
 
Example 26
Source Project: hottub   Source File: ParserVocabulary.java    License: GNU General Public License v2.0 5 votes vote down vote up
/** Creates a new instance of ParserVocabulary */
public ParserVocabulary() {
    namespaceName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    prefix = new PrefixArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);
    localName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    otherNCName = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, false);
    otherURI = new StringArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, true);
    attributeValue = new StringArray(ValueArray.DEFAULT_CAPACITY, NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS, true);
    otherString = new CharArrayArray(ValueArray.DEFAULT_CAPACITY, NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);

    characterContentChunk = new ContiguousCharArrayArray(ValueArray.DEFAULT_CAPACITY,
            NON_IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS,
            ContiguousCharArrayArray.INITIAL_CHARACTER_SIZE,
            NON_IDENTIFYING_STRING_TABLE_MAXIMUM_CHARACTERS);

    elementName = new QualifiedNameArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);
    attributeName = new QualifiedNameArray(ValueArray.DEFAULT_CAPACITY, IDENTIFYING_STRING_TABLE_MAXIMUM_ITEMS);

    tables[RESTRICTED_ALPHABET] = restrictedAlphabet;
    tables[ENCODING_ALGORITHM] = encodingAlgorithm;
    tables[PREFIX] = prefix;
    tables[NAMESPACE_NAME] = namespaceName;
    tables[LOCAL_NAME] = localName;
    tables[OTHER_NCNAME] = otherNCName;
    tables[OTHER_URI] = otherURI;
    tables[ATTRIBUTE_VALUE] = attributeValue;
    tables[OTHER_STRING] = otherString;
    tables[CHARACTER_CONTENT_CHUNK] = characterContentChunk;
    tables[ELEMENT_NAME] = elementName;
    tables[ATTRIBUTE_NAME] = attributeName;
}
 
Example 27
Source Project: hottub   Source File: ParserVocabulary.java    License: GNU General Public License v2.0 5 votes vote down vote up
private void addToTable(String s, StringArray a, StringIntMap m) {
    if (s.length() == 0) {
        return;
    }

    if (m != null) m.obtainIndex(s);
    a.add(s);
}
 
Example 28
Source Project: hottub   Source File: Decoder.java    License: GNU General Public License v2.0 5 votes vote down vote up
private void decodeTableItems(StringArray array) throws FastInfosetException, IOException {
    final int noOfItems = decodeNumberOfItemsOfSequence();

    for (int i = 0; i < noOfItems; i++) {
        array.add(decodeNonEmptyOctetStringOnSecondBitAsUtf8String());
    }
}
 
Example 29
Source Project: hottub   Source File: VocabularyGenerator.java    License: GNU General Public License v2.0 5 votes vote down vote up
public void addToTable(String s, Set v, StringIntMap m, StringArray a) {
    if (s.length() == 0) {
        return;
    }

    if (m.obtainIndex(s) == KeyIntMap.NOT_PRESENT) {
        a.add(s);
    }

    v.add(s);
}
 
Example 30
Source Project: hottub   Source File: PrintTable.java    License: GNU General Public License v2.0 5 votes vote down vote up
public static void printArray(String title, StringArray a) {
    System.out.println(title);

    for (int i = 0; i < a.getSize(); i++) {
        System.out.println("" + (i + 1) + ": " + a.getArray()[i]);
    }
}