• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

Java FinalArrayList类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Java中com.sun.istack.internal.FinalArrayList的典型用法代码示例。如果您正苦于以下问题:Java FinalArrayList类的具体用法?Java FinalArrayList怎么用?Java FinalArrayList使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



FinalArrayList类属于com.sun.istack.internal包,在下文中一共展示了FinalArrayList类的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: parseAttributes

import com.sun.istack.internal.FinalArrayList; //导入依赖的package包/类
/**
 * We don't really expect this to be used, but just to satisfy
 * the {@link Header} contract.
 *
 * So this is rather slow.
 */
private void parseAttributes() {
    try {
        XMLStreamReader reader = readHeader();

        attributes = new FinalArrayList<Attribute>();

        for (int i = 0; i < reader.getAttributeCount(); i++) {
            final String localName = reader.getAttributeLocalName(i);
            final String namespaceURI = reader.getAttributeNamespace(i);
            final String value = reader.getAttributeValue(i);

            attributes.add(new Attribute(namespaceURI,localName,value));
        }
    } catch (XMLStreamException e) {
        throw new WebServiceException("Unable to read the attributes for {"+nsUri+"}"+localName+" header",e);
    }
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:24,代码来源:OutboundStreamHeader.java


示例2: parseAttributes

import com.sun.istack.internal.FinalArrayList; //导入依赖的package包/类
/**
 * We don't really expect this to be used, but just to satisfy
 * the {@link Header} contract.
 *
 * So this is rather slow.
 */
private void parseAttributes() {
    try {
        XMLStreamReader reader = readHeader();
        reader.nextTag();   // move to the first element, which is the header element

        attributes = new FinalArrayList<Attribute>();
        boolean refParamAttrWritten = false;
        for (int i = 0; i < reader.getAttributeCount(); i++) {
            final String attrLocalName = reader.getAttributeLocalName(i);
            final String namespaceURI = reader.getAttributeNamespace(i);
            final String value = reader.getAttributeValue(i);
            if (namespaceURI.equals(AddressingVersion.W3C.nsUri)&& attrLocalName.equals("IS_REFERENCE_PARAMETER")) {
                refParamAttrWritten = true;
            }
            attributes.add(new Attribute(namespaceURI,attrLocalName,value));
        }
        // we are adding one more attribute "wsa:IsReferenceParameter", if its not alrady there
        if (!refParamAttrWritten) {
            attributes.add(new Attribute(AddressingVersion.W3C.nsUri,IS_REFERENCE_PARAMETER,TRUE_VALUE));
        }
    } catch (XMLStreamException e) {
        throw new WebServiceException("Unable to read the attributes for {"+nsUri+"}"+localName+" header",e);
    }
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:31,代码来源:OutboundReferenceParameterHeader.java


示例3: parseAttributes

import com.sun.istack.internal.FinalArrayList; //导入依赖的package包/类
/**
 * We don't really expect this to be used, but just to satisfy
 * the {@link Header} contract.
 *
 * So this is rather slow.
 */
private void parseAttributes() {
    try {
        XMLStreamReader reader = readHeader();
        reader.nextTag();   // move to the first element, which is the header element

        attributes = new FinalArrayList<Attribute>();
        boolean refParamAttrWritten = false;
        for (int i = 0; i < reader.getAttributeCount(); i++) {
            final String localName = reader.getAttributeLocalName(i);
            final String namespaceURI = reader.getAttributeNamespace(i);
            final String value = reader.getAttributeValue(i);
            if(namespaceURI.equals(AddressingVersion.W3C.nsUri)&& localName.equals("IS_REFERENCE_PARAMETER"))
                refParamAttrWritten = true;
            attributes.add(new Attribute(namespaceURI,localName,value));
        }
        // we are adding one more attribute "wsa:IsReferenceParameter", if its not alrady there
        if(!refParamAttrWritten)
            attributes.add(new Attribute(AddressingVersion.W3C.nsUri,IS_REFERENCE_PARAMETER,TRUE_VALUE));
    } catch (XMLStreamException e) {
        throw new WebServiceException("Unable to read the attributes for {"+nsUri+"}"+localName+" header",e);
    }
}
 
开发者ID:alexkasko,项目名称:openjdk-icedtea7,代码行数:29,代码来源:OutboundReferenceParameterHeader.java


示例4: processHeaderAttributes

import com.sun.istack.internal.FinalArrayList; //导入依赖的package包/类
protected final FinalArrayList<Attribute> processHeaderAttributes(XMLStreamReader reader) {
    FinalArrayList<Attribute> atts = null;

    _role = SOAPConstants.URI_SOAP_ACTOR_NEXT;

    for (int i = 0; i < reader.getAttributeCount(); i++) {
        final String localName = reader.getAttributeLocalName(i);
        final String namespaceURI = reader.getAttributeNamespace(i);
        final String value = reader.getAttributeValue(i);

        if (SOAPConstants.URI_NS_SOAP_1_1_ENVELOPE.equals(namespaceURI)) {
            if (SOAP_1_1_MUST_UNDERSTAND.equals(localName)) {
                _isMustUnderstand = Util.parseBool(value);
            } else if (SOAP_1_1_ROLE.equals(localName)) {
                if (value != null && value.length() > 0) {
                    _role = value;
                }
            }
        }

        if(atts==null) {
            atts = new FinalArrayList<Attribute>();
        }
        atts.add(new Attribute(namespaceURI,localName,value));
    }

    return atts;
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:29,代码来源:StreamHeader11.java


示例5: processHeaderAttributes

import com.sun.istack.internal.FinalArrayList; //导入依赖的package包/类
protected final FinalArrayList<Attribute> processHeaderAttributes(XMLStreamReader reader) {
    FinalArrayList<Attribute> atts = null;

    _role = SOAPConstants.URI_SOAP_1_2_ROLE_ULTIMATE_RECEIVER;

    for (int i = 0; i < reader.getAttributeCount(); i++) {
        final String localName = reader.getAttributeLocalName(i);
        final String namespaceURI = reader.getAttributeNamespace(i);
        final String value = reader.getAttributeValue(i);

        if (SOAPConstants.URI_NS_SOAP_1_2_ENVELOPE.equals(namespaceURI)) {
            if (SOAP_1_2_MUST_UNDERSTAND.equals(localName)) {
                _isMustUnderstand = Util.parseBool(value);
            } else if (SOAP_1_2_ROLE.equals(localName)) {
                if (value != null && value.length() > 0) {
                    _role = value;
                }
            } else if (SOAP_1_2_RELAY.equals(localName)) {
                _isRelay = Util.parseBool(value);
            }
        }

        if(atts==null) {
            atts = new FinalArrayList<Attribute>();
        }
        atts.add(new Attribute(namespaceURI,localName,value));
    }

    return atts;
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:31,代码来源:StreamHeader12.java


示例6: loadIndexedClasses

import com.sun.istack.internal.FinalArrayList; //导入依赖的package包/类
/**
 * Look for jaxb.index file in the specified package and load it's contents
 *
 * @param pkg package name to search in
 * @param classLoader ClassLoader to search in
 * @return a List of Class objects to load, null if there weren't any
 * @throws IOException if there is an error reading the index file
 * @throws JAXBException if there are any errors in the index file
 */
private static List<Class> loadIndexedClasses(String pkg, ClassLoader classLoader) throws IOException, JAXBException {
    final String resource = pkg.replace('.', '/') + "/jaxb.index";
    final InputStream resourceAsStream = classLoader.getResourceAsStream(resource);

    if (resourceAsStream == null) {
        return null;
    }

    BufferedReader in =
            new BufferedReader(new InputStreamReader(resourceAsStream, "UTF-8"));
    try {
        FinalArrayList<Class> classes = new FinalArrayList<Class>();
        String className = in.readLine();
        while (className != null) {
            className = className.trim();
            if (className.startsWith("#") || (className.length() == 0)) {
                className = in.readLine();
                continue;
            }

            if (className.endsWith(".class")) {
                throw new JAXBException(Messages.ILLEGAL_ENTRY.format(className));
            }

            try {
                classes.add(classLoader.loadClass(pkg + '.' + className));
            } catch (ClassNotFoundException e) {
                throw new JAXBException(Messages.ERROR_LOADING_CLASS.format(className, resource),e);
            }

            className = in.readLine();
        }
        return classes;
    } finally {
        in.close();
    }
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:47,代码来源:ContextFactory.java


示例7: addSubstitutionMember

import com.sun.istack.internal.FinalArrayList; //导入依赖的package包/类
private void addSubstitutionMember(ElementInfoImpl<T,C,F,M> child) {
    if(substitutionMembers==null)
        substitutionMembers = new FinalArrayList<ElementInfoImpl<T,C,F,M>>();
    substitutionMembers.add(child);
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:6,代码来源:ElementInfoImpl.java


示例8: makeSet

import com.sun.istack.internal.FinalArrayList; //导入依赖的package包/类
private static <T> List<T> makeSet( T... args ) {
    List<T> l = new FinalArrayList<T>();
    for( T arg : args )
        if(arg!=null)   l.add(arg);
    return l;
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:7,代码来源:ClassInfoImpl.java


示例9: link

import com.sun.istack.internal.FinalArrayList; //导入依赖的package包/类
@Override
protected void link(JAXBContextImpl grammar) {
    if(uriProperties!=null)
        return; // avoid linking twice

    super.link(grammar);

    if(superClazz!=null)
        superClazz.link(grammar);

    getLoader(grammar,true);    // make sure to build the loader if we haven't done so.

    // propagate values from super class
    if(superClazz!=null) {
        if(idProperty==null)
            idProperty = superClazz.idProperty;

        if(!superClazz.hasElementOnlyContentModel())
            hasElementOnlyContentModel(false);
    }

    // create a list of attribute/URI handlers
    List<AttributeProperty> attProps = new FinalArrayList<AttributeProperty>();
    List<Property> uriProps = new FinalArrayList<Property>();
    for (ClassBeanInfoImpl bi = this; bi != null; bi = bi.superClazz) {
        for (int i = 0; i < bi.properties.length; i++) {
            Property p = bi.properties[i];
            if(p instanceof AttributeProperty)
                attProps.add((AttributeProperty) p);
            if(p.hasSerializeURIAction())
                uriProps.add(p);
        }
    }
    if(grammar.c14nSupport)
        Collections.sort(attProps);

    if(attProps.isEmpty())
        attributeProperties = EMPTY_PROPERTIES;
    else
        attributeProperties = attProps.toArray(new AttributeProperty[attProps.size()]);

    if(uriProps.isEmpty())
        uriProperties = EMPTY_PROPERTIES;
    else
        uriProperties = uriProps.toArray(new Property[uriProps.size()]);
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:47,代码来源:ClassBeanInfoImpl.java



注:本文中的com.sun.istack.internal.FinalArrayList类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java DataSourceDatabaseTester类代码示例发布时间:2022-05-23
下一篇:
Java ResourceProvider类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap