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

Java XSSchema类代码示例

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

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



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

示例1: checkMultipleSchemaBindings

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
/** Reports an error if there are more than one jaxb:schemaBindings customization. */
private void checkMultipleSchemaBindings( XSSchema schema ) {
    ArrayList<Locator> locations = new ArrayList<Locator>();

    BindInfo bi = getBindInfo(schema);
    for( BIDeclaration bid : bi ) {
        if( bid.getName()==BISchemaBinding.NAME )
            locations.add( bid.getLocation() );
    }
    if(locations.size()<=1)    return; // OK

    // error
    getErrorReporter().error( locations.get(0),
        Messages.ERR_MULTIPLE_SCHEMA_BINDINGS,
        schema.getTargetNamespace() );
    for( int i=1; i<locations.size(); i++ )
        getErrorReporter().error( (Locator)locations.get(i),
            Messages.ERR_MULTIPLE_SCHEMA_BINDINGS_LOCATION);
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:20,代码来源:BGMBuilder.java


示例2: iterateElementDecls

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
public Iterator<XSElementDecl> iterateElementDecls() {
    return new Iterators.Map<XSElementDecl,XSSchema>(iterateSchema()) {
        protected Iterator<XSElementDecl> apply(XSSchema u) {
            return u.iterateElementDecls();
        }
    };
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:8,代码来源:SchemaSetImpl.java


示例3: iterateTypes

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
public Iterator<XSType> iterateTypes() {
    return new Iterators.Map<XSType,XSSchema>(iterateSchema()) {
        protected Iterator<XSType> apply(XSSchema u) {
            return u.iterateTypes();
        }
    };
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:8,代码来源:SchemaSetImpl.java


示例4: iterateAttributeDecls

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
public Iterator<XSAttributeDecl> iterateAttributeDecls() {
    return new Iterators.Map<XSAttributeDecl,XSSchema>(iterateSchema()) {
        protected Iterator<XSAttributeDecl> apply(XSSchema u) {
            return u.iterateAttributeDecls();
        }
    };
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:8,代码来源:SchemaSetImpl.java


示例5: iterateAttGroupDecls

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
public Iterator<XSAttGroupDecl> iterateAttGroupDecls() {
    return new Iterators.Map<XSAttGroupDecl,XSSchema>(iterateSchema()) {
        protected Iterator<XSAttGroupDecl> apply(XSSchema u) {
            return u.iterateAttGroupDecls();
        }
    };
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:8,代码来源:SchemaSetImpl.java


示例6: iterateModelGroupDecls

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
public Iterator<XSModelGroupDecl> iterateModelGroupDecls() {
    return new Iterators.Map<XSModelGroupDecl,XSSchema>(iterateSchema()) {
        protected Iterator<XSModelGroupDecl> apply(XSSchema u) {
            return u.iterateModelGroupDecls();
        }
    };
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:8,代码来源:SchemaSetImpl.java


示例7: iterateSimpleTypes

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
public Iterator<XSSimpleType> iterateSimpleTypes() {
    return new Iterators.Map<XSSimpleType,XSSchema>(iterateSchema()) {
        protected Iterator<XSSimpleType> apply(XSSchema u) {
            return u.iterateSimpleTypes();
        }
    };
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:8,代码来源:SchemaSetImpl.java


示例8: iterateComplexTypes

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
public Iterator<XSComplexType> iterateComplexTypes() {
    return new Iterators.Map<XSComplexType,XSSchema>(iterateSchema()) {
        protected Iterator<XSComplexType> apply(XSSchema u) {
            return u.iterateComplexTypes();
        }
    };
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:8,代码来源:SchemaSetImpl.java


示例9: iterateNotations

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
public Iterator<XSNotation> iterateNotations() {
    return new Iterators.Map<XSNotation,XSSchema>(iterateSchema()) {
        protected Iterator<XSNotation> apply(XSSchema u) {
            return u.iterateNotations();
        }
    };
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:8,代码来源:SchemaSetImpl.java


示例10: iterateIdentityConstraints

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
public Iterator<XSIdentityConstraint> iterateIdentityConstraints() {
    return new Iterators.Map<XSIdentityConstraint,XSSchema>(iterateSchema()) {
        protected Iterator<XSIdentityConstraint> apply(XSSchema u) {
            return u.getIdentityConstraints().values().iterator();
        }
    };
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:8,代码来源:SchemaSetImpl.java


示例11: getElementDecls

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
public List<XSElementDecl> getElementDecls() {
    ArrayList declList = new ArrayList();
    XSSchemaSet schemaSet = getRoot();
    for (XSSchema sch : schemaSet.getSchemas()) {
        for (XSElementDecl decl : sch.getElementDecls().values()) {
            if (decl.getType().equals(this)) {
                declList.add(decl);
            }
        }
    }
    return declList;
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:13,代码来源:SchemaSetImpl.java


示例12: schema

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
public void schema(XSSchema s) {
    // QUICK HACK: don't print the built-in components
    if (s.getTargetNamespace().equals(Const.schemaNamespace)) {
        return;
    }

    SchemaTreeNode newNode = new SchemaTreeNode("Schema "
            + s.getLocator().getSystemId(), s.getLocator());
    this.currNode = newNode;
    this.model.addSchemaNode(newNode);

    for (XSAttGroupDecl groupDecl : s.getAttGroupDecls().values()) {
        attGroupDecl(groupDecl);
    }

    for (XSAttributeDecl attrDecl : s.getAttributeDecls().values()) {
        attributeDecl(attrDecl);
    }

    for (XSComplexType complexType : s.getComplexTypes().values()) {
        complexType(complexType);
    }

    for (XSElementDecl elementDecl : s.getElementDecls().values()) {
        elementDecl(elementDecl);
    }

    for (XSModelGroupDecl modelGroupDecl : s.getModelGroupDecls().values()) {
        modelGroupDecl(modelGroupDecl);
    }

    for (XSSimpleType simpleType : s.getSimpleTypes().values()) {
        simpleType(simpleType);
    }
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:36,代码来源:SchemaTreeTraverser.java


示例13: visit

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
public void visit( XSSchemaSet s ) {
    Iterator itr =  s.iterateSchema();
    while(itr.hasNext()) {
        schema((XSSchema)itr.next());
        println();
    }
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:8,代码来源:SchemaWriter.java


示例14: schema

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
public void schema( XSSchema s ) {

        // QUICK HACK: don't print the built-in components
        if(s.getTargetNamespace().equals(Const.schemaNamespace))
            return;

        println(MessageFormat.format("<schema targetNamespace=\"{0}\">", s.getTargetNamespace()));
        indent++;

        Iterator itr;

        itr = s.iterateAttGroupDecls();
        while(itr.hasNext())
            attGroupDecl( (XSAttGroupDecl)itr.next() );

        itr = s.iterateAttributeDecls();
        while(itr.hasNext())
            attributeDecl( (XSAttributeDecl)itr.next() );

        itr = s.iterateComplexTypes();
        while(itr.hasNext())
            complexType( (XSComplexType)itr.next() );

        itr = s.iterateElementDecls();
        while(itr.hasNext())
            elementDecl( (XSElementDecl)itr.next() );

        itr = s.iterateModelGroupDecls();
        while(itr.hasNext())
            modelGroupDecl( (XSModelGroupDecl)itr.next() );

        itr = s.iterateSimpleTypes();
        while(itr.hasNext())
            simpleType( (XSSimpleType)itr.next() );

        indent--;
        println("</schema>");
    }
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:39,代码来源:SchemaWriter.java


示例15: iterator

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
public Iterator<XSSchema> iterator(Iterator<? extends XSComponent> contextNodes) {
    if(!contextNodes.hasNext())
        return Iterators.empty();
    else
        // this assumes that all current nodes belong to the same owner.
        return iterator(contextNodes.next());
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:8,代码来源:Axis.java


示例16: buildContents

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
/** Fill-in the contents of each classes. */
private void buildContents() {
    ClassSelector cs = getClassSelector();
    SimpleTypeBuilder stb = Ring.get(SimpleTypeBuilder.class);

    for( XSSchema s : Ring.get(XSSchemaSet.class).getSchemas() ) {
        BISchemaBinding sb = getBindInfo(s).get(BISchemaBinding.class);

        if(sb!=null && !sb.map) {
            sb.markAsAcknowledged();
            continue;       // no mapping for this package
        }

        getClassSelector().pushClassScope( new CClassInfoParent.Package(
            getClassSelector().getPackage(s.getTargetNamespace())) );

        checkMultipleSchemaBindings(s);
        processPackageJavadoc(s);
        populate(s.getAttGroupDecls(),s);
        populate(s.getAttributeDecls(),s);
        populate(s.getElementDecls(),s);
        populate(s.getModelGroupDecls(),s);

        // fill in typeUses
        for (XSType t : s.getTypes().values()) {
            stb.refererStack.push(t);
            model.typeUses().put( getName(t), cs.bindToType(t,s) );
            stb.refererStack.pop();
        }

        getClassSelector().popClassScope();
    }
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:34,代码来源:BGMBuilder.java


示例17: processPackageJavadoc

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
/**
 * Generates <code>package.html</code> if the customization
 * says so.
 */
private void processPackageJavadoc( XSSchema s ) {
    // look for the schema-wide customization
    BISchemaBinding cust = getBindInfo(s).get(BISchemaBinding.class);
    if(cust==null)      return; // not present

    cust.markAsAcknowledged();
    if( cust.getJavadoc()==null )   return;     // no javadoc customization

    // produce a HTML file
    JTextFile html = new JTextFile("package.html");
    html.setContents(cust.getJavadoc());
    getClassSelector().getPackage(s.getTargetNamespace()).addResourceFile(html);
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:18,代码来源:BGMBuilder.java


示例18: deriveName

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
/**
 * Derives a name from a schema component.
 *
 * This method handles prefix/suffix modification and
 * XML-to-Java name conversion.
 *
 * @param name
 *      The base name. This should be things like element names
 *      or type names.
 * @param comp
 *      The component from which the base name was taken.
 *      Used to determine how names are modified.
 */
public String deriveName( String name, XSComponent comp ) {
    XSSchema owner = comp.getOwnerSchema();

    name = getNameConverter().toClassName(name);

    if( owner!=null ) {
        BISchemaBinding sb = getBindInfo(owner).get(BISchemaBinding.class);

        if(sb!=null)    name = sb.mangleClassName(name,comp);
    }

    return name;
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:27,代码来源:BGMBuilder.java


示例19: run

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
/**
 * Runs the check.
 */
void run() {
    for( XSSchema s : Ring.get(XSSchemaSet.class).getSchemas() ) {
        schema(s);
        run( s.getAttGroupDecls() );
        run( s.getAttributeDecls() );
        run( s.getComplexTypes() );
        run( s.getElementDecls() );
        run( s.getModelGroupDecls() );
        run( s.getNotations() );
        run( s.getSimpleTypes() );
    }
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:16,代码来源:UnusedCustomizationChecker.java


示例20: schemaSet

import com.sun.xml.internal.xsom.XSSchema; //导入依赖的package包/类
public void schemaSet(XSSchemaSet xss) {
    if(!visited.add(xss))       return;

    for (XSSchema xs : xss.getSchemas()) {
        schema(xs);
    }
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:8,代码来源:RefererFinder.java



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


鲜花

握手

雷人

路过

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

请发表评论

全部评论

专题导读
上一篇:
Java HSAdminRefreshProtocolService类代码示例发布时间:2022-05-23
下一篇:
Java ChallengeState类代码示例发布时间: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