当前位置: 首页>>代码示例>>Java>>正文


Java Attributes.getType方法代码示例

本文整理汇总了Java中org.xml.sax.Attributes.getType方法的典型用法代码示例。如果您正苦于以下问题:Java Attributes.getType方法的具体用法?Java Attributes.getType怎么用?Java Attributes.getType使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.xml.sax.Attributes的用法示例。


在下文中一共展示了Attributes.getType方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: setAttributes

import org.xml.sax.Attributes; //导入方法依赖的package包/类
/**
 * Copy an entire Attributes object.
 *
 * @param atts The attributes to copy.
 */
public void setAttributes(Attributes atts) {
    _length = atts.getLength();
    if (_length > 0) {

        if (_length >= _algorithmData.length) {
            resizeNoCopy();
        }

        int index = 0;
        for (int i = 0; i < _length; i++) {
            _data[index++] = atts.getURI(i);
            _data[index++] = atts.getLocalName(i);
            _data[index++] = atts.getQName(i);
            _data[index++] = atts.getType(i);
            _data[index++] = atts.getValue(i);
            index++;
            _toIndex[i] = false;
            _alphabets[i] = null;
        }
    }
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:27,代码来源:EncodingAlgorithmAttributesImpl.java

示例2: setAttributes

import org.xml.sax.Attributes; //导入方法依赖的package包/类
/**
 * Copy an entire Attributes object.
 *
 * <p>It may be more efficient to reuse an existing object
 * rather than constantly allocating new ones.</p>
 *
 * @param atts The attributes to copy.
 */
public void setAttributes (Attributes atts)
{
    clear();
    length = atts.getLength();
    if (length > 0) {
        data = new String[length*5];
        for (int i = 0; i < length; i++) {
            data[i*5] = atts.getURI(i);
            data[i*5+1] = atts.getLocalName(i);
            data[i*5+2] = atts.getQName(i);
            data[i*5+3] = atts.getType(i);
            data[i*5+4] = atts.getValue(i);
        }
    }
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:24,代码来源:AttributesImpl.java

示例3: setAttributes

import org.xml.sax.Attributes; //导入方法依赖的package包/类
/**
 * Copy an entire Attributes object.
 *
 * <p>It may be more efficient to reuse an existing object
 * rather than constantly allocating new ones.</p>
 *
 * @param atts The attributes to copy.
 */
public void setAttributes (Attributes atts)
{
clear();
length = atts.getLength();
data = new String[length*5];
for (int i = 0; i < length; i++) {
    data[i*5] = atts.getURI(i);
    data[i*5+1] = atts.getLocalName(i);
    data[i*5+2] = atts.getQName(i);
    data[i*5+3] = atts.getType(i);
    data[i*5+4] = atts.getValue(i);
}
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:22,代码来源:AttributesImpl.java

示例4: fillXMLAttributes

import org.xml.sax.Attributes; //导入方法依赖的package包/类
private void fillXMLAttributes(Attributes atts) {
    fAttributes.removeAllAttributes();
    final int attrCount = atts.getLength();
    for (int i = 0; i < attrCount; ++i) {
        fillQName(fAttributeQName, atts.getURI(i), atts.getLocalName(i), atts.getQName(i));
        String type = atts.getType(i);
        fAttributes.addAttributeNS(fAttributeQName, (type != null) ? type : XMLSymbols.fCDATASymbol, atts.getValue(i));
        fAttributes.setSpecified(i, true);
    }
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:11,代码来源:SchemaContentHandler.java

示例5: fillXMLAttribute

import org.xml.sax.Attributes; //导入方法依赖的package包/类
/** Adds an attribute to the XMLAttributes object. */
private void fillXMLAttribute(Attributes att, int index) {
    fillQName(fAttributeQName, att.getURI(index), att.getLocalName(index), att.getQName(index));
    String type = att.getType(index);
    fAttributes.addAttributeNS(fAttributeQName, (type != null) ? type : XMLSymbols.fCDATASymbol, att.getValue(index));
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:7,代码来源:ValidatorHandlerImpl.java


注:本文中的org.xml.sax.Attributes.getType方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。