Movatterモバイル変換


[0]ホーム

URL:


W3C

Service Modeling LanguageInterchange Format Version 1.1

W3C Recommendation12 May 2009

This version:
http://www.w3.org/TR/2009/REC-sml-if-20090512/
Latest version:
http://www.w3.org/TR/sml-if/
Previous version:
http://www.w3.org/TR/2009/PR-sml-if-20090212/
Editors:
Bhalchandra Pandit, Microsoft Corporation
Valentina Popescu, IBM Corporation
Virginia Smith, HP

Please refer to theerrata for thisdocument, which may include some normative corrections.

This document is also available in these non-normative formats:XML.

See alsotranslations.

Copyright© 2009W3C® (MIT,ERCIM,Keio), All Rights Reserved.W3Cliability,trademarkanddocumentuse rules apply.


Abstract

This specification defines the interchange format for ServiceModeling Language, Version 1.1 (SML) models. This format identifiesthe model being interchanged, distinguishes between modeldefinition documents and model instance documents, and defines thebinding of rule documents with other documents in the interchangemodel.

Status of this Document

This section describes the status of this document at thetime of its publication. Other documents may supersede thisdocument. A list of current W3C publications and the latestrevision of this technical report can be found in theW3C technical reports index athttp://www.w3.org/TR/.

This is the 12 May 2009 W3C Recommendation of the ServiceModeling Language Interchange Format Version 1.1 specification.This document has been developed by theService Modeling Language (SML)Working Group, which is a part of theExtensible Markup Language (XML)Activity.

Comments on this document are welcome via the Working Group’spublic mailing list(publicarchive). Animplementationreport is available.

The design of SML has been widely reviewed and satisfies theWorking Group's technical requirements. Only minor editorialchanges have been made since the12 February 2009Proposed Recommendation.

This document has been reviewed by W3C Members, by softwaredevelopers, and by other W3C groups and interested parties, and isendorsed by the Director as a W3C Recommendation. It is a stabledocument and may be used as reference material or cited fromanother document. W3C's role in making the Recommendation is todraw attention to the specification and to promote its widespreaddeployment. This enhances the functionality and interoperability ofthe Web.

This document was produced by a group operating under the5February 2004 W3C Patent Policy. W3C maintains apublic list of anypatent disclosures made in connection with the deliverables ofthe group; that page also includes instructions for disclosing apatent. An individual who has actual knowledge of a patent whichthe individual believes containsEssential Claim(s) must disclose the information in accordancewithsection 6 of the W3C Patent Policy.

Table of Contents

1.Introduction(Non-Normative)
2.Notations andTerminology
    2.1Notational Conventions
    2.2Terminology
3.Dependencies on OtherSpecifications
4.Informal Description(Non-Normative)
    4.1Packaging
    4.2URIReferences
    4.3RuleBindings
    4.4SchemaBindings
    4.5Interoperability of SML Models
5.SML Interchange FormatDefinition
    5.1Conformance Criteria
    5.2SML-IFDocuments
        5.2.1Embedded Documents
        5.2.2Referenced Documents
        5.2.3Schema Completeness
        5.2.4SML-IF Document Version
    5.3URI References
        5.3.1URI equality
        5.3.2Base URIs
            5.3.2.1smlif:baseURI
        5.3.3Document Aliases
        5.3.4URI Reference Processing
    5.4DocumentBindings
        5.4.1URI Prefix Matching
        5.4.2Rule Bindings
        5.4.3Schema Bindings
6.References
    6.1Normative
    6.2Non-Normative

Appendices

A.SML-IF Schema
B.Localization of IF IdentitySample (Non-Normative)
C.Acknowledgements(Non-Normative)


1. Introduction(Non-Normative)

As defined in the Service Modeling Language, Version 1.1 (SML)Specification [SML 1.1] an SMLmodel is a collection of XML documents that may be used to describecomplex services and systems such as a set of IT resources,services and their interrelations.

In every SML model there are two distinguished subsets of themodel's documents, the definition documents and the instancedocuments. The model's definition documents describe the abstractstructure of the model, and provide much of the information a modelvalidator needs to decide whether the model, as a whole, is valid.The model's instance documents describe or support the descriptionof the individual resources that the model portrays.

The SML Specification identifies two categories of modeldefinition documents that participate in SML model validation:Schema documents and rule documents. Schema documents in a modelare XML documents that conform to the [SML1.1] defined extensions to XML Schema [XML Schema Structures,XMLSchema Datatypes]. Rule documents in a model include XMLdocuments that conform to the [SML1.1] defined extensions of Schematron [ISO/IEC 19757-3].

To ensure accurate and convenient interchange of the documentsthat make up an SML model, it is useful to define both animplementation-neutral interchange format that preserves thecontent and interrelationships among the documents and aconstrained form of SML model validation. For this purpose, thisspecification defines a standard format called the SML InterchangeFormat (SML-IF) and a process called interchange modelvalidation.

The specification consists of two parts. The first part is aninformal description of SML-IF to set the context. This is followedby SML-IF's normative definition.

2. Notations and Terminology

2.1 Notational Conventions

The keywords "MUST", "MUST NOT", "REQUIRED", "SHALL","SHALL NOT", "SHOULD", "SHOULDNOT", "RECOMMENDED","MAY", and "OPTIONAL" in this document are to be interpretedas described in RFC 2119 [IETF RFC2119].

This specification follows the same conventions for schemacomponents as those used in the XML schema specification[XML Schema Structures]. That is,references to properties of schema components are links to therelevant definition, set off with curly braces, for instance{example property}. References to properties of information itemsas defined in [XML InformationSet] are notated as links to the relevant sectionthereof, set off with square brackets, for example [children].

The content of this specification is normative except forsections or texts that are explicitly marked as non-normative. If asection is marked as non-normative, then all contained sub-sectionsare non-normative, even if they are not explicitly marked as such.All notes are non-normative unless otherwise specified.

2.2 Terminology

The following terms are used in this specification. They arelisted here in alphabetical order. This specification also usesterms defined in the [SML 1.1]specification.

Alias

Analias is a temporary name assigned to a model document[SML 1.1] within the context of aninterchange model.

Implementation-Defined

Animplementation-defined feature or behavior may varyamong processors conforming to this specification; the precisebehavior is not specified by this specification butMUST be specified by the implementor for eachparticular conforming implementation.

Implementation-Dependent

Animplementation-dependent feature or behavior may varyamong processors conforming to this specification; the precisebehavior is not specified by this or any other W3C specificationand is not required to be specified by the implementor for anyparticular implementation.

Interchange Model

Aninterchange model is an SML model [SML 1.1] being interchanged.

Interchange Model Validation

Interchange model validation is the process of performingSML model validation [SML 1.1] onthe interchange model while maintaining all assertions andinterrelationships among the documents in the interchange model asdefined by this specification.

Schema Binding

Aschema binding is an association of a namespace with aset of schema documents in theinterchange model and the instancedocuments [SML 1.1] that should bevalidated against this set of schema documents.

SML-IF Consumer

AnSML-IF consumer is a program that processes anSML-IF Document using, inwhole or part, semantics defined by this specification. It may ormay not performinterchange model validation.

SML-IF Document

AnSML-IF document is an XML representation of aninterchange model. Itincludes the model's identity, its documents (by value or byreference), metadata about its documents, and a syntacticrepresentation of concepts defined as part of an SML model butlacking an SML-defined sytnax (e.g. rule bindings).

SML-IF Producer

AnSML-IF producer is a program able to generate anSML-IF Document from an SMLmodel.

3. Dependencies onOther Specifications

Other specifications on which this one depends are listed in[Normative_References].

Conforming implementations of this specification MUST supportSML 1.1 [SML 1.1], XML 1.0[XML] and XML Schema 1.0[XML Schema Structures,XML Schema Datatypes]. Conformingimplementations MAY additionally support later versions of the XMLor XML Schema specifications.

Note:

AlthoughSML1.1 and SML-IF allow conforming implementations to supportnewer versions of dependent specifications, there areinteroperability implications to be considered when documents basedon those versions are interchanged using SML-IF. When an SML-IFdocument interchanges data built using newer versions of the SMLand SML-IF dependent specifications, consumers of the SML-IFdocument not supporting these versions may be unable to interpretsome of the data exchanged by this document.

4.Informal Description (Non-Normative)

To represent an SML model in a standard way for interchange, thefollowing topics need to be addressed.

Packaging: The collection of XML documents that make up amodel to be interchanged need to be gathered together. In doing so,the model definition and model instance documents need to bedistinguished from one another since they play distinct roles inthe model.

Explicit references: The documents to be interchanged mayexplicitly refer to one another and to documents that are notpackaged with the documents being interchanged. [SML 1.1] SML references among SML model instancedocuments are an obvious example. Less obvious are such referencesas certainschemaLocation attributes in schemadocuments andxsi:schemaLocation attributes ininstance documents. Section4.4Schema Bindings defines howschemaLocation isprocessed in these cases.

Rule bindings and schema bindings: [SML 1.1] permits models in which rule documentsapply to all, none, or subsets of the model's documents. SML-IFspecifies how to describe which rule documents apply to which ofthe model's documents.

Model validation: The process of SML model validationdefined in [SML 1.1] containspoints of variability that, left unconstrained, would make itdifficult for SML-IF to ensure interoperability of independentimplementations in any practical way. Many of these sources ofvariability are inherited from other specifications that SML uses,e.g. URI comparison RFC 3986 ([IETF RFC3986]) and the source of Schema components([XML Schema Structures]) used tovalidate model instance documents. SML-IF constrains these pointsof variability, with the goal of ensuring interoperability whenspecific conditions are met and of increasing the likelihood ofinteroperability in other cases. The enforcement of theseadditional constraints on SML model validation occurs during theprocess ofinterchangemodel validation.

4.1 Packaging

An SML-IF document packages a collection of SML model documentsto be interchanged as a single XML document. All SML-IF documentsconform to the XML Schema defined in the normative part of thisspecification.

Informally, the structure of SML-IF documents, using thepseudo-schema notation from WSDL 2.0 [WSDL2.0 Core Language] is as follows:

<?xml version="1.0" encoding="UTF-8"?><model xmlns="http://www.w3.org/ns/sml-if"       xmlns:xs="http://www.w3.org/2001/XMLSchema"       SMLIFVersion="xs:token Version number of the SML-IF spec used to generate the current document"       schemaComplete="xs:boolean">    <identity>        <name>            xs:anyURI Namespace identifying the model        </name>        <version> ?            xs:token <!-- The version of this model. E.g., 1.2 or 0.3 -->        </version>        <displayName sml:locid="xs:anyURI URI identifying the translation                                resource for the display name" ?> ?            xs:string Descriptive name of model intended for display        </displayName>        <baseURI>            xs:anyURI <!-- Base URI for relative references defined in the interchange model;                            must be an absolute reference -->        </baseURI> ?        <description sml:locid="xs:anyURI URI identifying the translation                                resource for the description" ?> ?            xs:string Textual description of model for human consumption        </description>    </identity>    <ruleBindings> ?        <ruleBinding> *            <documentAlias="xs:anyURI"/> ?            <ruleAlias="xs:anyURI"/>        </ruleBinding>    </ruleBindings>    <schemaBindings> ?        <defaultSchema> ?            <namespaceBinding/> *          </defaultSchema>        <schemaBinding> *            <namespaceBinding/> *              <documentAlias/> *             </schemaBinding>        <noSchemaBinding> ?            <documentAlias/> *             </noSchemaBinding>    </schemaBindings>    <definitions> ?        <document> *            <docInfo> ?                    <baseURI> ?                        xs:anyURI <!-- If a document has a baseURI, then this will be used to form the                                        base URI for all relative URIs subject to SML URI processing                                        contained by that document. -->                                </baseURI>                            <aliases> ?                        <alias> *                            xs:anyURI <!-- A URI by which SML references from other documents may refer to this document. -->                        </alias>                    </aliases>            </docInfo>                [                <data>                    xs:any <!-- At most one definition document goes here -->                </data>                |                <base64Data>                    xs:any <!-- At most one base64 encoded definition document goes here -->                </base64Data>                |                <locator>                    <documentURI/> ?                        xs:any <!-- A URI or IRI that points to a definition document goes here -->                </locator>                ]        </document>    </definitions>    <instances> ?        <document> *            <docInfo> ?                <baseURI> ?                     xs:anyURI <!-- If a document has a baseURI, then this will be used to form the                             base URI for all relative URIs subject to SML URI processing                             contained by that document. -->                            </baseURI>                        <aliases> ?                   <alias> *                       xs:anyURI <!-- A URI by which SML references from other documents may refer to this document. -->                                           </alias>                </aliases>            </docInfo>            [            <data>                xs:any<!-- At most one instance document goes here -->            </data>            |            <base64Data>                xs:any <!-- At most one base64 encoded instance document goes here -->            </base64Data>            |            <locator>                <documentURI/> ?                    xs:any <!-- A URI or IRI that points to an instance document goes here -->            </locator>            ]        </document>    </instances></model>

A document producer can specify the version of the specificationunder which the current document was generated, and with whichconformance is claimed, in theSMLIFVerion attribute.For example, if this version of SML-IF is used as the basis of adocument, the value of this attribute would be the value "1.1".

Theidentity element provides informationapplications can use to identify and describe the set of SMLdocuments being interchanged. ThebaseURI childelement is one way to specify a base URI to be used by relative URIreferences in theinterchangemodel. Another way to specify a base URI is to use thedocument/docInfo/baseURI element. [5.3.2 Base URIs]

TheSMLIFVersion attribute is defined on themodel element and may be useful when diagnosingfailures encountered while processing SML-IF documents. Forexample, if a document asserts conformance with version 1.1 of theSML-IF specification and a human can see that it is not in factconformant, then it is likely that the problem occurred during theproduction of the document. If the same document appears to humansto be conformant, then the focus of diagnosis might shift towardtheSML-IF consumer and itsinvocation parameters.

TheschemaComplete attribute is defined on themodel element and is used to indicate that the schemasconstructed from the definition documents in the interchange modelare complete, in the sense that the validity of the interchangedSML model is fully determined by these schemas. Formally, however,theschemaComplete attribute does not express anyassertion that the schemas so constructed are in fact complete, orthatinterchange modelvalidation using these schemas will not result in any errorsindicating that some components are missing from the schemas. Theonly formal effect ofschemaComplete attribute with avalue oftrue or1 is to specifyprecisely the schemas with which interchange model validation is tobe performed.

The optionalruleBindings element is used tocontain information that associates rule documents with thedocuments they apply to. See4.3 RuleBindings for further details.

Every document in theinterchange model appears as content of adocument element in either thedefinitions or theinstances element,depending on whether the document in question is a model definitionor a model instance document. There can be at most one embeddeddocument contained by adocument/data element. Bothdefinitions andinstances are optional.So, for example, if there are no model definition documents beingpackaged, thedefinitions element must be omitted.

The first child of eachdocument is typically adocInfo element that contains abaseURIelement and a list ofalias elements. ThebaseURI element can be used to specify a base URI forrelative references in the document. Defining base URIs isspecified in5.3.2 Base URIs. Thecontent of eachalias element is a URI with nofragment component (i.e., one with no "#" in it). Each of thealias elements serves as a name that other documentscan use to refer to this document. Examples of how aliases are usedto handle URI references are given in4.2 URI References.

A document in the interchange model can be represented in eitherof two ways, by embedding its content, or by providing a referenceto it. Which is being used is indicated by the child of thedocument element. A document can be embedded as-is orin a base64 encoded format. In the former case, adataelement is used to contain the actual content of the documentwhereas abase64Data element is used for the latter.The base64 format is typically used for, but is not restricted to,documents with DTD. If the document is being referenced rather thanembedded, alocator element is used to contain thereference. The content of alocator can be adocumentURI element defined by SML-IF or anything elseunderstood by theSML-IFconsumer.

Although it is not fully shown in the pseudo-schema above, theSML-IF schema has an "open content model." To provideextensibility, essentially every element in it can containadditional content and/or attributes from other XML namespaces.

4.2 URIReferences

When processing the SML model packaged inside an SML-IFdocument, certain URI references (as defined in RFC 3986[IETF RFC 3986]) may need to beprocessed to find their corresponding target. For example, in orderto assess SML validity of the interchanged model, SML referencesusing the SML URI Reference Scheme [SML1.1] need to be resolved. In addition, in order toassemble schemas from multiple schema documents as part of theinterchange model validity assessment, the schemaLocation attributeon anxs:include element needs to be processed tolocate the schema document.

To see how these URI references are handled, consider thefollowing SML-IF document:

<?xml version="1.0" encoding="UTF-8"?><model xmlns="http://www.w3.org/ns/sml-if" version="1.0">    <identity>        <name>http://www.university.example.org/sml/models/Sample/InterDocReferences</name>        <baseURI>http://www.university.example.org/Universities/</baseURI>       </identity>    <definitions>        <document>            <data>                <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">                    <xs:include schemaLocation="http://www.university.example.org/university/enrollmodel.xsd"/>                </xs:schema>                 </data>              </document>    </definitions>     <instances>        <document>            <data>                <Student xmlns="http://www.university.example.org/ns"                         xmlns:sml="http://www.w3.org/2007/09/sml"                         xmlns:u="http://www.university.example.org/ns">                    <ID>1000</ID>                    <Name>John Doe</Name>                    <EnrolledCourses>                        <EnrolledCourse sml:ref="true">                            <!-- SML Reference to a course INside the interchange model -->                                                                 <sml:uri>                                http://www.university.example.org/Universities/MIT/Courses.xml#smlxpath1(/u:Courses/u:Course[u:Name='PHY101'])                            </sml:uri>                        </EnrolledCourse>                        <EnrolledCourse sml:ref="true">                            <!-- SML Reference to a course INside the interchange model -->                                                    <sml:uri>                                http://www.university.example.org/Universities/SFU/Courses.xml#smlxpath1(/u:Courses/u:Course[u:Name='MUSIC205'])                            </sml:uri>                        </EnrolledCourse>                                   <EnrolledCourse sml:ref="true">                            <!-- SML Reference to a course OUTside the interchange model -->                                                    <sml:uri>                                http://www.university.example.org/Universities/Capella/Courses.xml#smlxpath1(/u:Courses/u:Course[u:Name='LIT103'])                            </sml:uri>                        </EnrolledCourse>                    </EnrolledCourses>                </Student>            </data>        </document>        <document>            <!-- The following alias matches the first course referenced above -->            <docInfo>                <aliases>                    <alias>http://www.university.example.org/Universities/MIT/Courses.xml</alias>                </aliases>            </docInfo>            <data>                <Courses xmlns="http://www.university.example.org/ns">                    <Course>                        <Name>PHY101</Name>                    </Course>                    <Course>                        <Name>MAT200</Name>                    </Course>                </Courses>            </data>        </document>        <document>            <docInfo>                <baseURI>SFU/Courses.xml</baseURI>                    <!-- The following alias matches the second course referenced above (after                    being converted to an absolute URI)  -->                </aliases>                    <alias>SFU/Courses.xml</alias>                </aliases>            </docInfo>            <data>                <Courses xmlns="http://www.university.example.org/ns">                    <Course>                        <Name>ENG106</Name>                    </Course>                    <Course>                        <Name>MUSIC205</Name>                    </Course>                </Courses>            </data>        </document>       </instances></model>

When not packaged in an SML-IF document, certain URI references(e.g. values ofsml:uri elements or certainschemaLocation attributes) are dereferenced to findtheir corresponding document. When these references are packaged inan SML-IF document, consumers of the SML-IF document need to firstexamine whether the target document or element is packaged in thesame SML-IF document. To determine this, the fragment component, ifany, is temporarily ignored to form a URI. This URI is thencompared against thealias URIs of packaged modeldocuments.

If the URI is equal to the URI in analias element(see5.3.1 URI equality), theSML-IF consumer will notattempt to look for targets of this URI outside of the SML-IFdocument, although there may exist a document retrievable at thisURI. If the URI is not equal to the URI in anyaliaselement, then the SML-IF document does not contain thecorresponding target of the original URI reference. The consumermay or may not attempt to look for targets outside of the SML-IFdocument, depending on the nature of the URI reference. Formalrules about how URI references are processed are defined in section5.3.4 URI ReferenceProcessing.

Several examples of resolving references can be seen in theexample SML-IF document shown above, illustrating the use of bothrelative and absolute alias URI values. In the first example, areference with an absolute URI, the following SML reference, mustfirst be separated into its document URI and fragmentcomponents:

http://www.university.example.org/Universities/MIT/Courses.xml#smlxpath1(/u:Courses/u:Course[u:Name='PHY101'])

After removing the fragment, the document portion of thereference is:

http://www.university.example.org/Universities/MIT/Courses.xml

This document URI is equal to the URI listed in analias accompanying theCourses document.So, by applying the fragment in the URI reference to theCourses document, we determine that the reference isto theCourse element whoseName elementhas"PHY101" as its content.

The second example reference, using a relative URI, is processedsimilarly. The full reference is:

http://www.university.example.org/Universities/SFU/Courses.xml#smlxpath1(/u:Courses/u:Course[u:Name='MUSIC205'])

After removing the fragment, the document portion of thereference is:

http://www.university.example.org/Universities/SFU/Courses.xml

This URI is equal to analias defined on the lastinstance document in the interchange model, after themodel/identity/baseURI content is applied to therelative URI contained by the document’saliaselement. So, by applying the fragment in the reference to theCourses document, we determine that the reference isto theCourse element whoseName elementhas"MUSIC205" as its content.

The third example, showing an unresolved reference, is processedsimilarly. The full reference is:

http://www.university.example.org/Universities/Capella/Courses.xml#smlxpath1(/u:Courses/u:Course[u:Name='LIT103'])

After removing the fragment, the document portion of thereference is:

http://www.university.example.org/Universities/Capella/Courses.xml

This document URI is not equal to the URI in anyalias element. This means that it is an unresolved SMLreference.

The URI:

http://www.university.example.org/university/enrollmodel.xsd

(value of theschemaLocation attribute on theinclude element) is not equal to anyalias. TheSML-IFconsumer may or may not attempt to locate a schema documentusing this URI reference.

4.3 RuleBindings

[SML 1.1] uses Schematronpatterns embedded in SML schemas and in separate explicitly boundrule documents to express constraints that cannot be expressed inXML Schemas. Schematron patterns embedded in SML Schema documentsall have well defined targets. [SML1.1] permits models in which rule documents apply toall, none, or subsets of the model's documents. SML-IF uses thelist ofruleBinding elements contained in the optionalruleBindings element to associate rule documents withthe documents in the interchange model to which they apply. EachruleBinding associates the documents having an aliasbeginning with the URI prefix given in thedocumentAlias with the rule documents having an aliasbeginning with the prefix given in theruleAlias. So,for example, theruleBinding:

<ruleBinding>    <documentAlias="http://www.university.example.org/sml/infrastructure/"/>    <ruleAlias="http://www.university.example.org/sml/infrastructurerules/"/></ruleBinding>

Would associate documents that have the aliases such as:

http://www.university.example.org/sml/infrastructure/server427.xml

and

http://www.university.example.org/sml/infrastructure/switch6E.xml

with rule documents that have aliases such as:

http://www.university.example.org/sml/infrastructurerules/assetistracked.sch

and

http://www.university.example.org/sml/infrastructurerules/managedbycorporate.sch

SML-IF specifies rule bindings among documents in theinterchange model. It does not specify rule bindings that apply todocuments not in the interchange model. That said, it is often thecase that the intent of transferring an SML-IF document is torelate its contents with other SML documents not in the interchangemodel. For example, the intent might be to merge the interchangemodel with an existing SML model. In such cases the context of usemay choose to extend the definition ofruleBinding tobind documents not in the interchange model. For example, if theinterchange model is merged into an existing model, the mergeprocess might choose to extend the definition ofruleBinding elements to bind rule documents in theinterchange model to documents in the merged model that weren'tincluded in the interchange model.

4.4 SchemaBindings

Schema documents can be connected with other schema documentsusing composition features provided by XML Schema. This includesxs:include,xs:redefine, andxs:import. A schema document's validity may depend onother schema documents it includes/redefines/imports, or even otherschema documents that include/redefine/import it. When performinginterchange modelvalidation over the SML model packaged in an SML-IF instance,an SML-IF consumer must draw associations between XML Schemadefinition documents and instance documents, both to completelyvalidate XML Schema documents themselves and to establish theschema-validity of the instance documents.

The XML Schema specification provides more flexibility inconstructing the schema used for assessment than is appropriate forthe semantics defined by SML and SML-IF forinterchange model validation.

  1. It allows XML Schema processors latitude in terms of locatingschema documents (resolving namespace and schema locationattributes) and composing schema documents together to form asingle schema.

  2. Schema location attributes can be ignored in some cases(xsi:schemaLocation in instance documents andschemaLocation attribute onxs:import)and allowed to "fail to resolve" in others(schemaLocation attribute onxs:includeandxs:import).

  3. Multiple imports of the same namespace allow all but the firstone to be ignored.

As a result, SML-IF cannot guarantee general caseinteroperability based only on XML Schema and, therefore, needs tospecify how to determine such associations. This section describesa method to achieve this goal.

An SML-IF document can be:

  1. Schema-complete - All schema documents are included inthe SML-IF document, either as an5.2.1 Embedded Documents or as5.2.2 ReferencedDocuments.

  2. Schema-incomplete - Some required schema documents maynot be included in the SML-IF document, either as an embeddeddocument or a referenced document.

It is necessary for an SML-IF producer to declarativelydistinguish between these two cases because making that distinctionis not always possible for anSML-IF consumer based on the content alone.SML-IF uses theschemaComplete attribute on themodel element to indicate whether this SML-IF documentincludes all necessary schema definition documents. When thisattribute is specified with a value of "true", then the schemavalidity of the schema definition documents and instance documentsdepend only on built-in components or components from definitiondocuments included in the SML-IF document. Built-in componentsinclude:

  1. four xsi: attributes (defined by XML Schema)

  2. all schema built-in types (xs:anyType and simple types definedin XML Schema Part 2)

  3. sml:ref attribute declaration

  4. sml:uri element declaration

An SML model represented by a schema-incomplete SML-IF documentis not necessarily invalid. However, SML-IF cannot guaranteeinteroperability for a schema-incomplete SML-IF document.

SML-IF uses a list ofschemaBinding elementscontained in the optionalschemaBindings element toassociate a namespace with a set of schema documents in theinterchange model and the instance documents that should bevalidated against this set of schema documents. EachnamespaceBinding child of aschemaBindingelement associates the namespace specified in itsnamespace attribute with the schema documents whosealiases are specified in itsaliases attribute. Inaddition, the instance documents that are to be assessed againstthis set of schemas are specified in thedocumentAliaschild element of the sameschemaBinding element.

The following example illustrates schema bindings.

<schemaBindings>    <!-- Each "schemaBinding" element corresponds to a schema and model         instance documents that are assessed against this schema -->    <schemaBinding>        <!-- all "namespaceBinding" children together build the schema -->        <namespaceBinding namespace="ns1" aliases="xsd1-a xsd1-b"/>        <namespaceBinding namespace="ns2" aliases="xsd2-v1"/>        <!-- list all applicable instances; same as for rule bindings -->        <documentAlias>doc1</documentAlias>        <documentAlias>doc2-v1-a</documentAlias>        <documentAlias>doc2-v1-b</documentAlias>    </schemaBinding>    <schemaBinding>        <namespaceBinding namespace="ns1" aliases="xsd1-a xsd1-b"/>        <namespaceBinding namespace="ns2" aliases="xsd2-v2"/>        <documentAlias>doc1</documentAlias>        <documentAlias>doc2-v2</documentAlias>    </schemaBinding></schemaBindings><definitions>    <!-- schema documents for xsd1-a, xsd1-b, xsd2-v1, xsd2-v2 --></definitions>

There are cases where many instance documents use the sameschema. In this case, it is desirable to have a default schemabinding rather than specifying aschemaBinding thatlists all these instance documents. ThedefaultSchemacan be used to cover instance documents not included in anyotherschemaBinding as in the following example.

<schemaBindings>    <!-- The "defaultSchema" element corresponds to a schema that governs         all instance documents *not* included in any "schemaBinding". -->    <defaultSchema>        <!-- all "namespaceBinding" children together build the schema -->        <namespaceBinding namespace="ns1" aliases="ns1.xsd"/>        <namespaceBinding namespace="ns2" aliases="ns2.xsd"/>    </defaultSchema></schemaBindings>

There may be cases where an instance document should not bebound to any schema, including the default schema. ThenoSchemaBinding element can be used in this case tocover such instance documents as in the following example.

<schemaBindings>    <!-- The "noSchemaBinding" element contains the aliases for          all instance documents *not* bound to any schema. -->    <noSchemaBinding>        <documentAlias>doc-a</documentAlias>        <documentAlias>doc-b</documentAlias>    </noSchemaBinding></schemaBindings>

4.5Interoperability of SML Models

The goal of SML-IF is to enable the exchange of SML models.However, this interoperability goal is affected by several aspectsof SML models.

  1. Use of the SML URI Reference Scheme as defined in the SMLspecification is the only guaranteed way of achievinginteroperability for all SML references in the model. Use of anyother reference scheme requires that theSML-IF consumer know about its use in thedocument and understand how to dereference it.

  2. SML documents can be included by reference using thelocator element and, therefore, are not directlyembedded in the SML-IF document. This can be very useful,especially when the SML-IF document is large or when the documentsare readily accessible to the consumer. However, thelocator element may be ignored by the consumer, maynot resolve, or may resolve to different resources in differentcontexts. Because of these uncertainties, interoperability is notguaranteed when documents are included by reference.

  3. The SML-IF document may be schema-incomplete [4.4 Schema Bindings]. An SML modelrepresented by a schema-incomplete SML-IF document is notnecessarily invalid. However, SML-IF cannot guaranteeinteroperability for a schema-incomplete SML-IF document.

  4. The SML-IF document may use reference schemes that do not usetarget-complete identifiers. In addition to the requirementsimposed by SML on reference scheme definitions, SML-IF imposesadditional requirements on references schemes that do not usetarget-complete identifiers in order to make them useful in thecontext of SML-IF [5.3.4 URI ReferenceProcessing].

  5. The presence of relative references subject to SML-IF URIprocessing introduces the necessity to transform them into absolutereferences [5.3.4 URI ReferenceProcessing]. SML-IF provides two alternative mechanisms[5.3.2 Base URIs] for doing so, oneof which is deprecated. SML-IF producers can construct SML-IFdocuments that use either only absolute URIs or both base URImechanisms in order to achieve interoperability with the maximumnumber of consumers.

5. SML Interchange FormatDefinition

This section normatively defines the Service Modeling LanguageInterchange Format (SML-IF). It defines the requirements thatSML-IF documents must adhere to and how URI references contained inthem are to be interpreted by consumers of SML-IF documents.

5.1Conformance Criteria

SML-IF defines two levels of conformance for SML-IFDocuments:

  1. Minimal Conformance: Aminimally conforming SML-IFDocumentMUST adhere to allSML-IF document requirements as described in the normative sectionsof this specification.

  2. Reference Conformance: Areferentially conforming SML-IFDocumentMUST adhere to allSML-IF document requirements as described in the normative sectionsof this specification. In addition, each non-null SML reference inthe documentMUST be an instance ofthe SML URI Reference Scheme [SML1.1].

Aconforming SML-IF ProducerMUST be able to generate a referentiallyconforming SML-IF Document from a conforming SML model.

Note:

When a producer generates a referentially conforming SML-IFdocument from a conforming source model, it is expected that thesource model and the generated model are equivalent. That is, thesource model and the destination model both have the same validity,same number of documents with similar structure and contentdiffering only in places where references are updated to haveequivalent SML URI scheme representation. However, thisspecification does not normatively define the notion of modelequivalence.

Aconforming SML-IF ConsumerMUST process a conforming SML-IF Document using,in whole or part, semantics defined by this specification. It isOPTIONAL that a conforming SML-IFConsumer process all elements defined in this specification, butany element that is processedMUST beprocessed according to the requirements stated in the normativesections of this specification. In particular, if a conformingSML-IF Consumer performsinterchange model validation, thenthat processMUST be performed asdescribed in this specification.

5.2 SML-IFDocuments

The purpose of SML-IF is to package the set of documents thatconstitute an SML model into a standard format so that it can beexchanged in a standard way.

An SML-IF documentMUST be awell-formed XML document [XML].

An SML-IF documentMUST be validunder the XML Schema given in Appendix A.

The definition and instance documents packaged by an SML-IFdocumentMAY form a valid SML modelbut it is not required to do so.

Each document in the interchange modelMUST be represented in the SML-IF document by aseparatedocument element as follows:

  1. Each definition document in the interchange modelMUST appear as a descendant of amodel/definitions/document element. The order of thedocument children is not significant.

  2. Each instance document in the interchange modelMUST appear as a descendant of amodel/instances/document element. The order of thedocument children is not significant.

Each document in the interchange modelMUST be included in the SML-IF document either asan embedded document (where the document to be included is embeddedin the SML-IF document) or by including a reference to thedocument.

5.2.1Embedded Documents

Documents that are to be embedded in the SML-IF documentMUST be embedded as text or in anencoded format as follows:

  1. If the document is embedded as text, itMUST be included as the content of amodel/definitions/document/data element if it is adefinition document or amodel/instances/document/dataelement if it is an instance document. Eachmodel/*/document/data elementMUST contain at most one document.

  2. If the document is embedded in an encoded format, then the octetstream representing the documentMUSTbe encoded in base64 format. The resultant data streamMUST be embedded as the content of amodel/definitions/document/base64Data element if it isa definition document or amodel/instances/document/base64Data element if it isan instance document. Eachmodel/*/document/base64DataelementMUST contain at most onedocument. Documents that contain a DTDMUST be embedded in this encoded format.

When extracting an embedded document that is contained in abase64Data element, an SML-IF consumerMUST decode the content of thebase64Data element first and then process theresulting document as an embedded instance document. All embeddedinstance documents not encoded in base64MUST be processed as if they contained the sameDTD as the one associated with the SML-IF document.

If themodel/*/document/data element has no childelement, then an SML-IF consumerMUSTtreat the document as if it is not part of the interchange model.If themodel/*/document/base64Data element has azero-length sequence of octets as its value, then an SML-IFconsumerMUST treat the document as ifit is not part of the interchange model.

5.2.2 Referenced Documents

Documents that are to be referenced rather than embeddedMUST be included as follows:

  1. If the document is a definition document, the location of thedocumentMUST be included as thecontent of amodel/definitions/document/locatorelement.

  2. If the document is an instance document, the location of thedocumentMUST be included as thecontent of amodel/instances/document/locatorelement.

SML-IF specifies one way thatMAYbe used to provide the location of the referenced document, thedocumentURI element. It is a consequence ofdocumentURI schema definition that it contains a URIreference, i.e., it may be an absolute URI or relative reference.When it is a relative reference, the [base URI] property SHOULD beused to transform it to an absolute URI, as stated in [5.3.2 Base URIs].

An SML-IF consumerMAY choose tolocate a referenced document. If an SML-IF consumer chooses not tolocate a referenced document or if it attempts to locate thereferenced document and this attempt fails, then the SML-IFconsumerMUST treat the referenceddocument as if it is not part of theinterchange model. If either of theseconditions occurs, the SML-IF consumerSHOULD make its invoker aware of thiscondition.

5.2.3 Schema Completeness

Thesmlif:schemaComplete attribute is defined onthemodel element. The attribute indicates whether ornot all the definition documents required forinterchange model validation areincluded in theinterchangemodel.

IfschemaComplete has the valuetrueor1, then schemas used for interchange modelvalidationMUST contain only schemacomponents declared in built-in components or in model definitiondocuments within the interchange model. IfschemaComplete has the valuefalse or0, then this specification does not constrain whetheror not definition documents required for interchange modelvalidation are retrieved from outside the interchange model.

5.2.4 SML-IFDocument Version

An SML-IF producerMAY specify theversion of the SML-IF specification with which conformance isdeclared by including the version number of the relevantspecification as the value of theSMLIFVersionattribute in the document'smodel element. This valueMUST be"1.1" fordocuments declared by the producer to conform to the SML-IF 1.1specification. SML-IF ConsumersMUSTattempt to process an SML-IF document regardless of the value oftheSMLIFVersion attribute. That is, an SML-IFConsumerMUST NOT reject the documentsolely because of the value of theSMLIFVersionattribute.

Note:

RequiringSML-IFconsumers to continue processing in the face of unknown versionvalues makes it easier to deploy documents that support futureversions of this specification.

5.3 URI References

5.3.1 URIequality

SML-IF uses URI equality extensively to handle references amongdocuments in the interchange model. To determine whether two URIsare equal,SML-IF consumersMUST perform case sensitivecodepoint-by-codepoint comparison of the corresponding charactersin the URI references.

5.3.2 Base URIs

If a document in the interchange model contains a relativereference subject to SML-IF URI processing (see5.3.4 URI Reference Processing), thenthe base URI used to transform the relative URI reference into anabsolute URI is the value of its [base URI] property according tothe rules in section 4.3 ofXMLBase. When a base URI is needed to transform a relativereference, then the information necessary to calculate the [baseURI] propertyMUST be embedded withinthe SML-IF document’s content using at least one of the followingmechanisms.

  1. The base URI is embedded using thexml:baseattribute according toXMLBase. The value of an element's [base URI] property iscalculated according toXMLBase.

  2. The base URI is embedded using thesmlif:baseURIelement as described in5.3.2.1smlif:baseURI. The value of an element's [base URI]property is calculated as described in that section.

Note:

Because this specification requires that the base URIinformation be embedded in the document content, it follows that anelement’s [base URI] will never be computed from the URI of thedocument entity or external entity (see section 4.2 ofXML Base) containing theelement.

SML-IF consumersMUST support at least one of thesemechanisms. The selection of which base URI mechanism(s) aconsumer’s implementation supports is implementation-defined, i.e.it might be done as a fixed coding choice, as a run-time parameter,by scanning the content, or through any other means.SML-IF producersMUST supportxml:base andMAY supportsmlif:baseURI.

If an SML-IF consumer supports both mechanisms and theinterchange model document it is consuming contains markup for bothmechanisms, then the SML-IF consumerMUST use the [base URI] value calculated using thexml:base mechanism.

All of the base URI mechanisms used in each interchange modeldocumentMUST be used consistently. Inother words, all of the base URI mechanisms whose markup appears inthe documentMUST result in the s ame[base URI] value being calculated for each relative referencesubject to SML-IF URI processing. SML-IF consumersMAY check this consistency.

Note:

As a consequence of the granularity of the consistencyrequirement, a single SML-IF document may use different mechanismsin distinct interchange model documents. In this scenario, it istrue that only consumers that support all mechanisms used would beable to process the entire SML-IF document correctly.

Consistency checking of base URI results by SML-IF consumers ismade optional to avoid requiring the potential overhead ofperforming twice as many calculations per relative reference as isminimally required to consume the model. An SML-IF consumer mightchoose to check base URI mechanism consistency based on inputparameters, always, never, or based on any other criteria itchooses. If both base URI mechanisms are used in a giveninterchange model document contained within a conforming SML-IFdocument, and a consumer understands both mechanisms, such aconsumer must use the xml:base mechanism to compute the [base URI]property. This consumer may choose to ignore the smlif:baseURIinformation or it may choose to verify that consistent results areobtained from both mechanisms. If both base URI mechanisms are usedin a given interchange model document contained within anon-conforming SML-IF document, SML-IF provides no guarantees aboutthe consistency of any [base URI] property computed using bothmechanisms.

SML-IF producers have several combinations to consider whendefining base URIs in an SML-IF document:

  1. When the interchange model contains no relative URI referencessubject to SML-IF URI processing, neitherxml:base norsmlif:baseURI is necessary.

  2. When relative URI references subject to SML-IF URI processingexist in the interchange model and all require the same base URIvalue, providing anxml:base orsmlif:baseURI value for the model element issufficient.

  3. When relative URI references subject to SML-IF URI processingexist in the interchange model and they require different base URIvalues, a combination ofxml:base values or acombination ofsmlif:baseURI values can be used toensure each document has the correct base URI.

  4. When relative URI references subject to SML-IF URI processingexist within the same SML model document and they require differentbase URI values,xml:base can be used within thedocument to ensure that each relative URI has the correct baseURI.

5.3.2.1smlif:baseURI

This syntax is supported in this version of the SML-IFspecification for compatibility with existing SML-IF documents. Itis, however, deprecated and may be removed in a future version ofthis specification.

In thesmlif:baseURI mechanism, two base URI valuesvalues are used to compute the value of an element’s [base URI]property, which is then used to resolve relative URI referencesdefined in the interchange model that are subject to SML-IF URIprocessing (see5.3.4 URI ReferenceProcessing).

Interchange model base URI

A URI reference that complies with the “absolute-URI” productionas defined in RFC 3986 ([IETF RFC3986]). The value of theinterchange model baseURI is the content of the/model/identity/baseURIelement, if any.

Note:

This is roughly equivalent to specifying the same value in anxml:base attribute on the /model element.

Document base URI

A URI reference that complies with the “absolute-URI” productionas defined in RFC 3986 ([IETF RFC3986]). Each document in the interchange model has adocument base URI whose value is a computed value.

For each document in the interchange model, the value of thedocument base URI iscomputed as follows:

  1. If the document has adocInfo/baseURI element, letU be its value.

    1. IfU is a relative reference, letB be the valueof theinterchange modelbase URI. Then the value of the document base URI is the resultof transformingU into an absolute URI, usingB asthe base URI.

    2. Otherwise the value of the document base URI isU.

  2. Otherwise if theinterchange model base URI has a value,then the value of the document base URI is the value of theinterchange model base URI.

  3. Otherwise, the document base URI has no value.

According to thesmlif:baseURI mechanism, the [baseURI] property of an element is calculated as follows:

  1. If the element is part of a document in the interchange model(i.e. it has as one of its ancestor elements smlif:locator,smlif:data, smlif:base64Data), its [base URI] value is thedocument base URI.

  2. Otherwise, its [base URI] value is theinterchange model base URI.

5.3.3Document Aliases

For each document in theinterchange model, thedocument element contains a set of zero or morealias elements that are used to define thealiases of the document.

Conceptually, each document in the interchange model has thefollowing property:

[aliases]

A set of URI references that comply with the “absolute-URI”production as defined in RFC 3986 ([IETFRFC 3986]).

The value of the content of[aliases] is computed as follows:

  1. For eachalias child element under the modeldocument’sdocInfo/aliases, there is a correspondingmember in the[aliases]. LetU be the value of such child element:

    1. IfU is a relative reference, letB be value ofthe [base URI] property of the containingaliaselement, then[aliases] containsthe result of transformingU into an absolute URI, usingB as the base URI, as defined in section 5 of RFC 3986([IETF RFC 3986]).

    2. Otherwise[aliases] containsU.

AliasesMUST be unique. That is,thereMUST NOT exist two modeldocuments whose[aliases]properties overlap.

Note:

As a consequence of the above property definition’s reliance onthe “absolute-URI” production, thealias elementsMUST NOT contain fragmentcomponents.

5.3.4 URIReference Processing

When processing an SML-IF document, there are 3 categories ofURI references that may need to be resolved:

  1. schemaLocation attributes onxs:include andxs:redefine in schemadocuments, when they are model definition documents.

  2. URI references specified in instances of SML reference schemesthat use target-complete identifiers [SML1.1].

  3. URI references specified in instances of SML reference schemesthat do not use target-complete identifiers.

It is clear which references fall into category #1. An exampleof category #2 is URI references used in SML references that usethe SML URI Reference Scheme. When new reference schemes that useURI references are defined, whether they fall into category #2 or#3 will be clear from the reference scheme definitions. Resolutionof URI references in category #3 is defined in their respectivescheme definitions. It is also possible to have reference schemesthat do not use URI references. Their resolution is governed bytheir scheme definitions and is not covered by this section.

To process a URI referenceUR that is within categories#1 or #2 above, the following steps are performed:

  1. Determine the documentD that possibly contains thetarget:

    1. IfUR is a same-document reference [IETF RFC 3986], thenD is the modeldocument that containsUR.

    2. Otherwise

      1. IfUR has a fragment component, then letUR' bethe URI reference formed by removing the fragment component;otherwise letUR' beUR.

      2. IfUR' is a relative reference, then transformUR'to form an (absolute) URIU, using its [base URI] as thebase URI, as defined in section 5 of RFC 3986 ([IETF RFC 3986]); otherwise letU beUR'.

      3. If there exists a model document with an alias URI that is equaltoU (5.3.1 URIequality), thenD is that document; otherwiseD has no value.

  2. IfD has no value, then

    1. IfUR is within category #1(schemaLocation), then the SML-IF document does notcontain the target schema document. Whether theSML-IF consumer continues to dereferenceUR orU is governed by other sections of thisspecification.

    2. Otherwise (UR is within category #2, used in an SMLreference),UR has no target.

  3. IfD has a value, then

    1. IfUR is within category #1(schemaLocation), thenUR has a target if andonly if all of the following are true.

      1. D is a schema document that is also a model definitiondocument in the interchange model.

      2. UR does not contain a fragment component.

    2. IfUR is within category #2, then

      1. IfUR does not contain a fragment component, then ittargets the root element of D.

      2. Otherwise (UR contains a fragment component), thefragment component ofUR is applied to the root element ofD, which may result in 0, 1, or many target elements.

To process a URI reference UR that is within category #3 above,a set of steps corresponding to those described above forcategories #1 and #2 MUST be defined as part of the referencescheme definition.

5.4Document Bindings

5.4.1 URI Prefix Matching

To associate SML rule or schema documents with the subset ofdocuments in the model to which they apply, SML-IF uses acombination of thealias mechanismdescribed above [5.3.3 DocumentAliases] and URI prefix matching.

Two URIs, one called theprefix, and one called thetarget participate in URI prefix matching. The target issaid to match the prefix if and only if the target, truncated tothe length of the prefix, is equal to the prefix as defined insection5.3.1 URI equality.

5.4.2 Rule Bindings

A rule binding is an association of a set of one or more ruledocuments with a set of zero or more model documents. The documentsassociated with a given rule document are said to be "bound" to it.For a model to be valid, every document in the model must conformto the constraints defined by every rule document it is bound to.It is permissible for a rule document to have no bindingsassociated with it, and for a model document to be bound to zerorule documents.

TheruleBinding element is used in SML-IF toexpress rule bindings. In any given binding the set of ruledocuments is that subset of rule documents in the interchange modelwith an alias that matches the URI prefix given by the content oftheruleAlias element. The set of model documents inthe binding is that subset of the documents in the interchangemodel with an alias that matches the URI prefix given by thecontent of thedocumentAlias element. If thedocumentAlias element is omitted in aruleBinding, the set of model documents in the bindingis all documents in the interchange model.

Note:

Since the URI prefixes specified asruleAlias anddocumentAlias elements are aliases, they are subjectto all of the processing for aliases as described in [5.3.3 Document Aliases]. Forexample, if they are relative references then they would betransformed to absolute URIs before comparison.

SML-IF consumersMAY choose toextend the sets of documents involved in bindings to includedocuments not contained in the interchange model. For example, ifan SML-IF document is used to represent a model fragment that isintended to be merged with some other model, it is entirelypossible that some or all of the bindings may involve not just thedocuments in the interchange model, but documents in the othermodel.

5.4.3 Schema Bindings

SML-IF consumersMAY choose toignore theschemaBindings element when present in theSML-IF document, in which case the consumerSHOULD make its invoker aware of thissituation.

If an SML-IF consumer chooses to process the schemaBindingselement, then, as part of theinterchange model validation, forevery schema bindingSB in the model, i.e. every/model/schemaBindings/schemaBinding element, theSML-IF consumerMUST perform thefollowing steps for instance document validation.

  1. Compose a schema using all documents specified under allSB'snamespaceBinding children.

  2. Whenever animport for a namespaceN isencountered, perform the following steps.

    1. If there is anamespaceBinding child ofSBwhosenamespace attribute matchesN, thencomponents from schema documents listed in the correspondingaliases attribute are used. As with rule bindings, URIprefixing [5.4.1 URI PrefixMatching] is used for matching schema document aliases. Atmost onenamespaceBinding is allowed per namespaceN within a givenSB. If more than one namespacebinding exists for the namespace as part of a single schemabinding, the SML-IF document is in error. If the set of aliases fornamespaceN is empty, the namespace has no schema documentsdefining it in the schema binding.

    2. Otherwise, if there are schema documents in the SML-IF documentwhose targetNamespace isN, then components from all thoseschema documents are used.

    3. Otherwise, if this is a schema-complete SML-IF document(/model/@schemaComplete = "true"), then no componentfromN (other than built-ins) is included in the schemabeing composed.

    4. Otherwise, it is implementation-defined whether SML-IF consumerattempts to retrieve components forN from outside theSML-IF document.

  3. Whenever aninclude orredefine isencountered, theschemaLocation is used to matchaliases of schema documents, as with base SML-IF.

    1. If there is a schema document in the SML-IF document matchingthat alias, then that document is used.

    2. Otherwise, if this is a schema-complete SML-IF document, thentheinclude orredefine is unresolved(which is allowed by XML Schema validity assessment rules).

    3. Otherwise, it is implementation-defined whether an SML-IFconsumer attempts to resolveinclude orredefine to schema documents outside the SML-IFdocument.

  4. The instance documents that are referenced in thedocumentAlias element ofSBMUST be validated against the schema constructedin steps 1 through 3.sml:target* and SML identityconstraints can now be checked. Similar todocumentAlias underruleBinding elements[5.4.2 RuleBindings], eachdocumentAlias can refer tomultiple documents via URI prefixing.

Whether or not aschemaBindings element is presentor is ignored, SML-IF consumersMUSTprocess aninclude orredefine element asdescribed in step 3 above.

The common use case where match-all namespace matching isdesired can be achieved by omittingschemaBindingswithout introducing any additional complexity into the SML-IFdocument.

If an SML-IF consumer chooses to process theschemaBindings element, then the following rulesregarding the default schema must be followed:

  1. If the optionaldefaultSchema element is present,then an SML-IF consumerMUST compose adefault schema from this element following rules 1 to 3 above,replacingSB in the text withDS (i.e., the/model/schemaBindings/defaultSchema element).

  2. Otherwise, an SML-IF consumerMUSTcompose a default schema using all schema documents included in theSML-IF document.

  3. An SML-IF consumerMUST use thisdefault schema to validate those SML instance documents whose aliasis not matched by anydocumentAlias in aschemaBinding element ornoSchemaBindingelement. Note that URI prefixing [5.4.1 URI Prefix Matching] isused for matching document aliases.

In all other cases, the SML-IF consumerMUST compose a schema using all schema documentsincluded in the SML-IF document andMUST use this schema to validate all instancedocuments in theinterchangemodel.

Note:

Examples of these cases include:

  1. An SML-IF consumer chooses not to process the schemaBindingselement.

  2. No schema documents are found among the SML-IF document'sdefinition documents.

Note:

The distinction between schema and schema documents is bothintentional and important; the absence of schema documents does notimply the absence of a schema. A schema containing only built-incomponents will be constructed given zero schema documents asinput, and this schema will be used to validate all instancedocuments in the interchange model. This distinction has an impacton model validation results according to the definition of validityfor a conforming SML model [5.1Conformance Criteria].

6. References

6.1 Normative

[SML 1.1]
Service ModelingLanguage, Version 1.1, Bhalchandra Pandit, ValentinaPopescu, Virginia Smith, Editors. World Wide Web Consortium, 12 May2009. This version of the Service Modeling Language specificationis available at http://www.w3.org/TR/2009/REC-sml-20090512/. Thelatest version of ServiceModeling Language, Version 1.1 is available athttp://www.w3.org/TR/sml/.
[XML SchemaStructures]
XML SchemaPart 1: Structures Second Edition, H. Thompson, D.Beech, M. Maloney, and N. Mendelsohn, Editors. World Wide WebConsortium, 2 May 2001, revised 28 October 2004. This version ofthe XML Schema Part 1 Recommendation ishttp://www.w3.org/TR/2004/REC-xmlschema-1-20041028. Thelatest version of XML SchemaPart 1 is available at http://www.w3.org/TR/xmlschema-1.
[XML SchemaDatatypes]
XML SchemaPart 2: Datatypes Second Edition, P. Byron and A.Malhotra, Editors. World Wide Web Consortium, 2 May 2001, revised28 October 2004. This version of the XML Schema Part 2Recommendation ishttp://www.w3.org/TR/2004/REC-xmlschema-2-20041028. Thelatest version of XML SchemaPart 2 is available at http://www.w3.org/TR/xmlschema-2.
[XML]
Extensible MarkupLanguage (XML) 1.0 (Fourth Edition), T. Bray, J. Paoli,C. M. Sperberg-McQueen, and E. Maler, Editors. World Wide WebConsortium, 10 February 1998, revised 16 August 2006. The editioncited (http://www.w3.org/TR/2006/REC-xml-20060816) was the onecurrent at the date of publication of this specification as aCandidate Recommendation. Thelatest version of XML 1.0 isavailable at http://www.w3.org/TR/xml/. Implementations may followthe edition cited and/or any later edition(s); it isimplementation-defined which editions are supported by animplementation.
[XMLInformation Set]
XMLInformation Set, John Cowan and Richard Tobin, Editors.World Wide Web Consortium, 4 February 2004. This version of the XMLInfoset Recommendation ishttp://www.w3.org/TR/2004/REC-xml-infoset-20040204/. Thelatest version of the XMLInfoset is available at http://www.w3.org/TR/xml-infoset/.
[XMLBase]
XMLBase, Jonathan Marsh, Editor. World Wide Web Consortium,27 June 2001. This version of the XML Base Recommendation ishttp://www.w3.org/TR/2001/REC-xmlbase-20010627/. Thelatest version of XML Base isavailable at http://www.w3.org/TR/xmlbase/.
[IETF RFC3986]
UniformResource Identifier (URI): Generic Syntax, T.Berners-Lee, R. Fielding, L. Masinter Authors. Internet EngineeringTask Force, January 2005. Available athttp://www.ietf.org/rfc/rfc3986.txt.
[IETF RFC2119]
Key wordsfor use in RFCs to Indicate Requirement Levels, S.Bradner, Author. Internet Engineering Task Force, June 1999.Available at http://www.ietf.org/rfc/rfc2119.txt.

6.2 Non-Normative

[ISO/IEC19757-3]
Information technology ― Document Schema Definition Languages(DSDL) ― Part 3: Rule-based validation ― Schematron.International Organization for Standardization and InternationalElectrotechnical Commission, 1 January 2006. Available athttp://standards.iso.org/ittf/PubliclyAvailableStandards/c040833_ISO_IEC_19757-3_2006(E).zip
[CanonicalXML]
CanonicalXML, J. Boyer, Author. World Wide Web Consortium, 15March 2001. This version of the Canonical XML Recommendation ishttp://www.w3.org/TR/2001/REC-xml-c14n-20010315. Thelatest version of Canonical XMLis available at http://www.w3.org/TR/xml-c14n.
[XML-Signature]
XML-SignatureSyntax and Processing, D. Eastlake, J. Reagle, and D.Solo, Editors. Internet Engineering Task Force & World Wide WebConsortium, 12 February 2002. This version of the XML-SignatureSyntax and Processing Recommendation ishttp://www.w3.org/TR/2002/REC-xmldsig-core-20020212/. Thelatest version ofXML-Signature Syntax and Processing is available athttp://www.w3.org/TR/xmldsig-core/.
[WS-Addressing Core]
Web ServicesAddressing 1.0 - Core, M. Gudgin, M. Hadley, and T.Rogers, Editors. World Wide Web Consortium, 9 May 2006. Thisversion of the WS-Addressing Core Recommendation ishttp://www.w3.org/TR/2006/REC-ws-addr-core-20060509/. Thelatest version ofWS-Addressing Core is available athttp://www.w3.org/TR/ws-addr-core/.
[WSDL 2.0 CoreLanguage]
Web ServicesDescription Language (WSDL) Version 2.0 Part 1: CoreLanguage, R. Chinnici, M. Gudgin, J-J. Moreau, S.Weerawarana, Editors. World Wide Web Consortium, 23 May 2007. Thisversion of the "Web Services Description Language (WSDL) Version2.0 Part 1: Core Language" Specification is available is availableat http://www.w3.org/TR/2007/PR-wsdl20-20070523/. Thelatest version of "Web ServicesDescription Language (WSDL) Version 2.0 Part 1: Core Language"is available at http://www.w3.org/TR/wsdl20/.
[XLink]
XML LinkingLanguage (XLink) Version 1.0, Steve DeRose, Eve Maler,David Orchard, Editors. World Wide Web Consortium, 27 June 2001.This version of the XLink Recommendation ishttp://www.w3.org/TR/2001/REC-xlink-20010627/ Thelatest version of XLink isavailable at http://www.w3.org/TR/xlink/.

A. SML-IFSchema

<!--/* * Copyright © ns World Wide Web Consortium, * * (Massachusetts Institute of Technology, European Research Consortium for * Informatics and Mathematics, Keio University). All Rights Reserved. This * work is distributed under the W3C® Document License [1] in the hope that * it will be useful, but WITHOUT ANY WARRANTY; without even the implied * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * * [1] http://www.w3.org/Consortium/Legal/2002/copyright-documents-20021231 */--><xs:schema      xmlns:smlif="http://www.w3.org/ns/sml-if"      xmlns:xs="http://www.w3.org/2001/XMLSchema"      targetNamespace="http://www.w3.org/ns/sml-if"      elementFormDefault="qualified"      blockDefault="#all"      version="1.0"      xml:lang="EN"      finalDefault=""      attributeFormDefault="unqualified">   <xs:element name="model" type="smlif:modelType"/>   <xs:complexType name="modelType" mixed="false">      <xs:sequence>         <xs:element name="identity" type="smlif:identityType"/>         <xs:element ref="smlif:ruleBindings" minOccurs="0"/>         <xs:element ref="smlif:schemaBindings" minOccurs="0"/>         <xs:element               name="definitions"               type="smlif:documentCollectionType"               minOccurs="0"/>         <xs:element               name="instances"               type="smlif:documentCollectionType"               minOccurs="0"/>         <xs:any               namespace="##other"               processContents="lax"               minOccurs="0"               maxOccurs="unbounded"/>      </xs:sequence>      <xs:attribute            name="SMLIFVersion"            type="xs:token"            use="optional"/>      <xs:attribute            name="schemaComplete"            type="xs:boolean"            default="false"/>      <xs:anyAttribute            namespace="##other"            processContents="lax"/>   </xs:complexType>   <!-- If there is a need for localized string values, e.g. in displayName         or description, the sml:locid global attribute can be         used -->   <xs:complexType name="identityType" mixed="false">      <xs:sequence>         <xs:element name="name" type="smlif:uriType"/>         <xs:element               name="version"               type="smlif:tokenType"               minOccurs="0"/>         <xs:element               name="displayName"               type="smlif:displayType"               minOccurs="0"/>         <xs:element               name="baseURI"               type="smlif:uriType"               minOccurs="0"/>         <xs:element               name="description"               type="smlif:displayType"               minOccurs="0"/>         <xs:any               namespace="##other"               processContents="lax"               minOccurs="0"               maxOccurs="unbounded"/>      </xs:sequence>      <xs:anyAttribute            namespace="##other"            processContents="lax"/>   </xs:complexType>   <xs:complexType name="displayType" mixed="false">      <xs:simpleContent>         <xs:extension base="xs:string">            <xs:anyAttribute                  namespace="##other"                  processContents="lax"/>         </xs:extension>      </xs:simpleContent>   </xs:complexType>   <xs:complexType name="tokenType" mixed="false">      <xs:simpleContent>         <xs:extension base="xs:token">            <xs:anyAttribute                  namespace="##other"                  processContents="lax"/>         </xs:extension>      </xs:simpleContent>   </xs:complexType>   <xs:complexType name="uriType" mixed="false">      <xs:simpleContent>         <xs:extension base="xs:anyURI">            <xs:anyAttribute                  namespace="##other"                  processContents="lax"/>         </xs:extension>      </xs:simpleContent>   </xs:complexType>   <xs:element         name="ruleBindings"         type="smlif:ruleBindingCollectionType"/>   <xs:complexType         name="ruleBindingCollectionType"         mixed="false">      <xs:sequence>         <xs:element               ref="smlif:ruleBinding"               maxOccurs="unbounded"/>         <xs:any               namespace="##other"               processContents="lax"               minOccurs="0"               maxOccurs="unbounded"/>      </xs:sequence>      <xs:anyAttribute            namespace="##other"            processContents="lax"/>   </xs:complexType>   <xs:element name="ruleBinding" type="smlif:ruleBindingType"/>   <xs:complexType name="ruleBindingType" mixed="false">      <xs:sequence>         <xs:element               name="documentAlias"               type="smlif:uriType"               minOccurs="0"/>         <xs:element name="ruleAlias" type="smlif:uriType"/>         <xs:any               namespace="##other"               processContents="lax"               minOccurs="0"               maxOccurs="unbounded"/>      </xs:sequence>      <xs:anyAttribute            namespace="##other"            processContents="lax"/>   </xs:complexType>   <xs:element         name="schemaBindings"         type="smlif:schemaBindingCollectionType"/>   <xs:complexType         name="schemaBindingCollectionType"         mixed="false">      <xs:sequence>         <xs:element ref="smlif:defaultSchema" minOccurs="0"/>         <xs:element               ref="smlif:schemaBinding"               minOccurs="0"               maxOccurs="unbounded"/>         <xs:element               ref="smlif:noSchemaBinding"               minOccurs="0"               maxOccurs="1"/>         <xs:any               namespace="##other"               processContents="lax"               minOccurs="0"               maxOccurs="unbounded"/>      </xs:sequence>      <xs:anyAttribute            namespace="##other"            processContents="lax"/>   </xs:complexType>   <xs:element         name="schemaBinding"         type="smlif:schemaBindingType"/>   <xs:complexType name="schemaBindingType" mixed="false">      <xs:sequence>         <xs:element               ref="smlif:namespaceBinding"               minOccurs="0"               maxOccurs="unbounded"/>         <xs:element               name="documentAlias"               type="smlif:uriType"               minOccurs="0"               maxOccurs="unbounded"/>         <xs:any               namespace="##other"               processContents="lax"               minOccurs="0"               maxOccurs="unbounded"/>      </xs:sequence>      <xs:anyAttribute            namespace="##other"            processContents="lax"/>   </xs:complexType>   <xs:element         name="namespaceBinding"         type="smlif:namespaceBindingType"/>   <!-- The value of the aliases attribute in the complexType below        is a list of instance document URIs -->   <xs:complexType name="namespaceBindingType" mixed="false">      <xs:attribute            name="namespace"            type="xs:anyURI"            use="optional"/>      <xs:attribute name="aliases" use="required">         <xs:simpleType>            <xs:list itemType="xs:anyURI"/>         </xs:simpleType>      </xs:attribute>      <xs:anyAttribute            namespace="##other"            processContents="lax"/>   </xs:complexType>   <xs:element         name="noSchemaBinding"         type="smlif:noSchemaBindingType"/>   <xs:complexType name="noSchemaBindingType" mixed="false">      <xs:sequence>         <xs:element               name="documentAlias"               type="smlif:uriType"               minOccurs="0"               maxOccurs="unbounded"/>         <xs:any               namespace="##other"               processContents="lax"               minOccurs="0"               maxOccurs="unbounded"/>      </xs:sequence>      <xs:anyAttribute            namespace="##other"            processContents="lax"/>   </xs:complexType>   <xs:element         name="defaultSchema"         type="smlif:defaultSchemaType"/>   <xs:complexType name="defaultSchemaType" mixed="false">      <xs:sequence>         <xs:element               ref="smlif:namespaceBinding"               minOccurs="0"               maxOccurs="unbounded"/>         <xs:any               namespace="##other"               processContents="lax"               minOccurs="0"               maxOccurs="unbounded"/>      </xs:sequence>      <xs:anyAttribute            namespace="##other"            processContents="lax"/>   </xs:complexType>   <xs:complexType name="documentCollectionType" mixed="false">      <xs:sequence>         <xs:element ref="smlif:document" maxOccurs="unbounded"/>         <xs:any               namespace="##other"               processContents="lax"               minOccurs="0"               maxOccurs="unbounded"/>      </xs:sequence>      <xs:anyAttribute            namespace="##other"            processContents="lax"/>   </xs:complexType>   <xs:element name="document" type="smlif:documentType"/>   <xs:complexType name="documentType" mixed="false">      <xs:sequence>         <xs:element ref="smlif:docinfo" minOccurs="0"/>         <xs:choice>            <xs:element name="data" type="smlif:dataType"/>            <xs:element                  name="base64Data"                  type="smlif:base64DataType"/>            <xs:element name="locator" type="smlif:locatorType"/>         </xs:choice>         <xs:any               namespace="##other"               processContents="lax"               minOccurs="0"               maxOccurs="unbounded"/>      </xs:sequence>      <xs:anyAttribute            namespace="##other"            processContents="lax"/>   </xs:complexType>   <xs:element name="docinfo" type="smlif:docinfoType"/>   <xs:complexType name="docinfoType" mixed="false">      <xs:sequence>         <xs:element               name="baseURI"               type="smlif:uriType"               minOccurs="0"/>         <xs:element ref="smlif:aliases" minOccurs="0"/>         <xs:any               namespace="##other"               processContents="lax"               minOccurs="0"               maxOccurs="unbounded"/>      </xs:sequence>      <xs:anyAttribute            namespace="##other"            processContents="lax"/>   </xs:complexType>   <xs:element name="aliases" type="smlif:aliasCollectionType"/>   <xs:complexType name="aliasCollectionType" mixed="false">      <xs:sequence>         <xs:element               name="alias"               type="smlif:uriType"               minOccurs="0"               maxOccurs="unbounded"/>         <xs:any               namespace="##other"               processContents="lax"               minOccurs="0"               maxOccurs="unbounded"/>      </xs:sequence>      <xs:anyAttribute            namespace="##other"            processContents="lax"/>   </xs:complexType>   <xs:complexType name="dataType" mixed="false">      <xs:annotation>         <xs:documentation>                The wildcard with processContents "skip" matches the root element of the                  model document being packaged. The value of processContents is set to "skip" so                that the contained element is not processed for schema validation. As a result,                validity of the packaged document will not affect validity of the IF document                itself.            </xs:documentation>      </xs:annotation>      <xs:sequence>         <xs:any               processContents="skip"               minOccurs="0"               namespace="##any"               maxOccurs="1"/>      </xs:sequence>      <xs:anyAttribute            namespace="##other"            processContents="lax"/>   </xs:complexType>   <xs:complexType name="base64DataType" mixed="false">      <xs:simpleContent>         <xs:extension base="xs:base64Binary">            <xs:anyAttribute                  namespace="##other"                  processContents="lax"/>         </xs:extension>      </xs:simpleContent>   </xs:complexType>   <xs:complexType name="locatorType" mixed="false">      <xs:sequence>         <xs:element               name="documentURI"               type="smlif:uriType"               minOccurs="0"/>         <xs:any               namespace="##other"               processContents="lax"               minOccurs="0"               maxOccurs="unbounded"/>      </xs:sequence>      <xs:anyAttribute            namespace="##other"            processContents="lax"/>   </xs:complexType></xs:schema>

B.Localization of IF Identity Sample (Non-Normative)

The following example shows how thesml:locidattribute can be used to define the translation information for theinterchange model identity attributes:

<model xmlns="http://www.w3.org/ns/sml-if" version="1.0"       xmlns:sml="http://www.w3.org/ns/sml">       xmlns:lang="http://www.university.example.org/translation/core">    <identity>        <name sml:locid="lang:nameID“>Univerity interchange model</name>        <description sml:locid="lang:descrID"> This document contains a list of universities.</description>    </identity></model>

In this example, the [namespace name] URI information of thesml:locid attribute can be used to define the locationfor the resource containing the translated text. Thesmlif:name andsmlif:description elementsare using the same URI to identify the resource containing thetranslated strings:

<xmlns:lang="http://www.university.example.org/translation/core">

The [local part] information of thesml:locidattribute can be used to define the id of the text beingtranslated. This information will be used to locate the translationof the name and description texts within the translationresource.

C.Acknowledgements (Non-Normative)

The editors acknowledge the members of the Service ModelingLanguage Working Group, the members of other W3C Working Groups,and industry experts in other forums who have contributed directlyor indirectly to the process or content of creating thisdocument.

At the time this specification was published, the members of theService Modeling Language Working Group were:

John Arwe (IBM Corporation), Len Charest (MicrosoftCorporation), Sandy Gao (IBM Corporation), Paul Lipton (CA), JamesLynn (HP), Kumar Pandit (Microsoft Corporation), Valentina Popescu(IBM Corporation), Virginia Smith (HP), Henry Thompson (W3C/ERCIM),David Whiteman (IBM Corporation), Kirk Wilson (CA).

The Service Modeling Language Working Group has benefited in itswork from the participation and contributions of a number of peoplenot currently members of the Working Group, including in particularthose named below.

Dave Ehnebuske (IBM), Jon Hass (Dell), Steve Jerman (Cisco),Heather Kreger (IBM), Vincent Kowalski (BMC), Milan Milenkovic(Intel), Bryan Murray (HP), Phil Prasek (HP), Junaid Saiyed (EMC),Harm Sluiman (IBM), C. Michael Sperberg-McQueen (W3C/MIT), BassamTabbara (Microsoft), Vijay Tewari (Intel), William Vambenepe (HP),Marv Waschke (CA), Andrea Westerinen (Microsoft), Pratul Dublish(Microsoft), Julia McCarthy (IBM).

Affiliations given above are those current at the time of theirwork with the working group.


[8]ページ先頭

©2009-2025 Movatter.jp