OASIS XML Localisation Interchange File Format (XLIFF) TC

 View Only
Expand all | Collapse all

RE: [xliff] Extensibility methods

  • 1.  RE: [xliff] Extensibility methods

    Posted 05-04-2012 15:14
    Hi David,   We defined core and module, conducted a ballot and approved both definitions. They are included in the specification draft. I agree with you, <matches should live in a module and I tried to move it to a module. Unfortunately, <matches> content is too related to <source> and <target> and we cannot separate <matches> from the rest using namespaces.   Regards, Rodolfo -- Rodolfo M. Raya Maxprograms http://www.maxprograms.com    


  • 2.  RE: [xliff] Extensibility methods

    Posted 05-04-2012 15:52
    Do we have a running list of element and attributes which are core and which are considered modules? David Corporate Globalization Tool Development EMail:  waltersd@us.ibm.com           Phone: (507) 253-7278,   T/L:553-7278,   Fax: (507) 253-1721 CHKPII:                     http://w3-03.ibm.com/globalization/page/2011 TM file formats:     http://w3-03.ibm.com/globalization/page/2083 TM markups:         http://w3-03.ibm.com/globalization/page/2071 "Rodolfo M. Raya" ---05/04/2012 10:15:10 AM---Hi David,   We defined core and module, conducted a ballot and approved both definitions. They are i From: "Rodolfo M. Raya" <rmraya@maxprograms.com> To: "XLIFF TC" <xliff@lists.oasis-open.org> Date: 05/04/2012 10:15 AM Subject: RE: [xliff] Extensibility methods Sent by: <xliff@lists.oasis-open.org> Hi David,   We defined core and module, conducted a ballot and approved both definitions. They are included in the specification draft. I agree with you, <matches should live in a module and I tried to move it to a module. Unfortunately, <matches> content is too related to <source> and <target> and we cannot separate <matches> from the rest using namespaces.   Regards, Rodolfo -- Rodolfo M. Raya Maxprograms http://www.maxprograms.com    


  • 3.  RE: [xliff] Extensibility methods

    Posted 05-04-2012 17:19
    Hi David,   We have a draft in PDF and HTML format and also two schemas in our SVN repository. One schema contains the core and the other the glossary module. The glossary module is documented in an annex of the specification, separated from the core.   Regards, Rodolfo -- Rodolfo M. Raya       rmraya@maxprograms.com Maxprograms       http://www.maxprograms.com   From: xliff@lists.oasis-open.org [mailto:xliff@lists.oasis-open.org] On Behalf Of David Walters Sent: Friday, May 04, 2012 12:51 PM To: Rodolfo M. Raya Cc: XLIFF TC Subject: RE: [xliff] Extensibility methods   Do we have a running list of element and attributes which are core and which are considered modules? David Corporate Globalization Tool Development EMail:   waltersd@us.ibm.com           Phone: (507) 253-7278,   T/L:553-7278,   Fax: (507) 253-1721 CHKPII:                     http://w3-03.ibm.com/globalization/page/2011 TM file formats:     http://w3-03.ibm.com/globalization/page/2083 TM markups:         http://w3-03.ibm.com/globalization/page/2071 "Rodolfo M. Raya" ---05/04/2012 10:15:10 AM---Hi David,   We defined core and module, conducted a ballot and approved both definitions. They are i From: "Rodolfo M. Raya" < rmraya@maxprograms.com > To: "XLIFF TC" < xliff@lists.oasis-open.org > Date: 05/04/2012 10:15 AM Subject: RE: [xliff] Extensibility methods Sent by: < xliff@lists.oasis-open.org > Hi David,   We defined core and module, conducted a ballot and approved both definitions. They are included in the specification draft. I agree with you, <matches should live in a module and I tried to move it to a module. Unfortunately, <matches> content is too related to <source> and <target> and we cannot separate <matches> from the rest using namespaces.   Regards, Rodolfo -- Rodolfo M. Raya Maxprograms http://www.maxprograms.com    


  • 4.  RE: [xliff] Extensibility methods

    Posted 05-04-2012 18:14
    So all of these elements, along with these inline elements ( <cp> , <ph> , <pc> , <sc> , <ec>, <mrk> . ) are currently defined as "core"? <xliff> 1 +---<file> +            +---<skeleton> ?            +---<unit> +                     +---<segment> +                            +---<source> 1                            +---<target> ?                            +---<notes> ?                                    +---<simpleNote> +                            +---<matches> ?                                     +---<match> +                                                +---<source> 1                                                +---<target> 1                                                +---<originalData> ?                                                         +---<data> +                     +---<ignorable> *                            +---<source> 1                            +---<target> ?                     +---<notes> ?                            +---<simpleNote> +                     +---<matches> ?                            +---<match> +                                     +---<source> 1                                     +---<target> 1                                     +---<originalData> ?                                                +---<data> +                     +---<originalData> ?                                +---<data> +           <cp> , <ph> , <pc> , <sc> , <ec> and <mrk> . The elements David Corporate Globalization Tool Development EMail:  waltersd@us.ibm.com           Phone: (507) 253-7278,   T/L:553-7278,   Fax: (507) 253-1721 CHKPII:                     http://w3-03.ibm.com/globalization/page/2011 TM file formats:     http://w3-03.ibm.com/globalization/page/2083 TM markups:         http://w3-03.ibm.com/globalization/page/2071 "Rodolfo M. Raya" ---05/04/2012 12:24:47 PM---Hi David, From: "Rodolfo M. Raya" <rmraya@maxprograms.com> To: <xliff@lists.oasis-open.org> Date: 05/04/2012 12:24 PM Subject: RE: [xliff] Extensibility methods Sent by: <xliff@lists.oasis-open.org> Hi David,   We have a draft in PDF and HTML format and also two schemas in our SVN repository. One schema contains the core and the other the glossary module. The glossary module is documented in an annex of the specification, separated from the core.   Regards, Rodolfo -- Rodolfo M. Raya       rmraya@maxprograms.com Maxprograms       http://www.maxprograms.com   From:  xliff@lists.oasis-open.org [ mailto:xliff@lists.oasis-open.org ] On Behalf Of David Walters Sent:  Friday, May 04, 2012 12:51 PM To:  Rodolfo M. Raya Cc:  XLIFF TC Subject:  RE: [xliff] Extensibility methods   Do we have a running list of element and attributes which are core and which are considered modules? David Corporate Globalization Tool Development EMail:   waltersd@us.ibm.com             Phone: (507) 253-7278,   T/L:553-7278,   Fax: (507) 253-1721 CHKPII:                     http://w3-03.ibm.com/globalization/page/2011 TM file formats:     http://w3-03.ibm.com/globalization/page/2083 TM markups:         http://w3-03.ibm.com/globalization/page/2071 "Rodolfo M. Raya" ---05/04/2012 10:15:10 AM---Hi David,   We defined core and module, conducted a ballot and approved both definitions. They are i From: "Rodolfo M. Raya" < rmraya@maxprograms.com > To: "XLIFF TC" < xliff@lists.oasis-open.org > Date: 05/04/2012 10:15 AM Subject: RE: [xliff] Extensibility methods Sent by: < xliff@lists.oasis-open.org > Hi David, We defined core and module, conducted a ballot and approved both definitions. They are included in the specification draft. I agree with you, <matches should live in a module and I tried to move it to a module. Unfortunately, <matches> content is too related to <source> and <target> and we cannot separate <matches> from the rest using namespaces. Regards, Rodolfo -- Rodolfo M. Raya Maxprograms http://www.maxprograms.com  


  • 5.  RE: [xliff] Extensibility methods

    Posted 05-04-2012 19:15
    Yes David. Currently anything core is define here: http://tools.oasis-open.org/version-control/svn/xliff/trunk/schemas/xliff_core_2.0.xsd   -ys   From: xliff@lists.oasis-open.org [mailto:xliff@lists.oasis-open.org] On Behalf Of David Walters Sent: Friday, May 04, 2012 12:13 PM To: Rodolfo M. Raya Cc: xliff@lists.oasis-open.org Subject: RE: [xliff] Extensibility methods   So all of these elements, along with these inline elements ( <cp> , <ph> , <pc> , <sc> , <ec>, <mrk> .) are currently defined as "core"? <xliff> 1 +---<file> +            +---<skeleton> ?            +---<unit> +                     +---<segment> +                            +---<source> 1                            +---<target> ?                            +---<notes> ?                                    +---<simpleNote> +                            +---<matches> ?                                     +---<match> +                                                +---<source> 1                                                +---<target> 1                                                +---<originalData> ?                                                         +---<data> +                     +---<ignorable> *                            +---<source> 1                            +---<target> ?                     +---<notes> ?                            +---<simpleNote> +                     +---<matches> ?                            +---<match> +                                     +---<source> 1                                     +---<target> 1                                     +---<originalData> ?                                                +---<data> +                     +---<originalData> ?                                +---<data> +           <cp> , <ph> , <pc> , <sc> , <ec> and <mrk> . The elements David Corporate Globalization Tool Development EMail:   waltersd@us.ibm.com           Phone: (507) 253-7278,   T/L:553-7278,   Fax: (507) 253-1721 CHKPII:                     http://w3-03.ibm.com/globalization/page/2011 TM file formats:     http://w3-03.ibm.com/globalization/page/2083 TM markups:         http://w3-03.ibm.com/globalization/page/2071 "Rodolfo M. Raya" ---05/04/2012 12:24:47 PM---Hi David, From: "Rodolfo M. Raya" < rmraya@maxprograms.com > To: < xliff@lists.oasis-open.org > Date: 05/04/2012 12:24 PM Subject: RE: [xliff] Extensibility methods Sent by: < xliff@lists.oasis-open.org > Hi David,   We have a draft in PDF and HTML format and also two schemas in our SVN repository. One schema contains the core and the other the glossary module. The glossary module is documented in an annex of the specification, separated from the core.   Regards, Rodolfo -- Rodolfo M. Raya       rmraya@maxprograms.com Maxprograms       http://www.maxprograms.com   From:   xliff@lists.oasis-open.org [ mailto:xliff@lists.oasis-open.org ] On Behalf Of David Walters Sent:  Friday, May 04, 2012 12:51 PM To:  Rodolfo M. Raya Cc:  XLIFF TC Subject:  RE: [xliff] Extensibility methods   Do we have a running list of element and attributes which are core and which are considered modules? David Corporate Globalization Tool Development EMail:   waltersd@us.ibm.com             Phone: (507) 253-7278,   T/L:553-7278,   Fax: (507) 253-1721 CHKPII:                     http://w3-03.ibm.com/globalization/page/2011 TM file formats:     http://w3-03.ibm.com/globalization/page/2083 TM markups:         http://w3-03.ibm.com/globalization/page/2071 "Rodolfo M. Raya" ---05/04/2012 10:15:10 AM---Hi David,   We defined core and module, conducted a ballot and approved both definitions. They are i From: "Rodolfo M. Raya" < rmraya@maxprograms.com > To: "XLIFF TC" < xliff@lists.oasis-open.org > Date: 05/04/2012 10:15 AM Subject: RE: [xliff] Extensibility methods Sent by: < xliff@lists.oasis-open.org > Hi David, We defined core and module, conducted a ballot and approved both definitions. They are included in the specification draft. I agree with you, <matches should live in a module and I tried to move it to a module. Unfortunately, <matches> content is too related to <source> and <target> and we cannot separate <matches> from the rest using namespaces. Regards, Rodolfo -- Rodolfo M. Raya Maxprograms http://www.maxprograms.com  


  • 6.  RE: [xliff] Extensibility methods

    Posted 05-04-2012 20:39
      |   view attached
    Hi David, Rodolfo, all, > I agree with you, <matches> should live in a module > and I tried to move it to a module. Unfortunately, > <matches> content is too related to <source> and > <target> and we cannot separate <matches> from the > rest using namespaces. I agree too that it should be in a separate module. I'm certainly no expert in XML Schema, and I may be wrong, but we should be able to use types of the XLIFF core into other modules. Complex types can be used recursively, so I don't see why they could not be used recursively across namespaces as well. If I declare <matches> and <match> in a separate XSD module, using a reference to the source, target and originalData types declared in the core, like this: <xs:element name="match"> <xs:complexType> <xs:sequence> <xs:element minOccurs="1" maxOccurs="1" ref="xlf:source"/> <xs:element minOccurs="1" maxOccurs="1" ref="xlf:target"/> <xs:element minOccurs="0" maxOccurs="1" ref="xlf:originalData"/> </xs:sequence> <xs:attribute name="id" use="optional" type="xs:NMTOKEN"/> <xs:attribute name="origin" use="optional"/> <xs:attribute name="matchquality" use="optional" type="xs:integer"/> </xs:complexType> </xs:element> And in the core module do this: <xs:element name="segment"> <xs:complexType> <xs:sequence> <xs:element minOccurs="1" maxOccurs="1" ref="xlf:source"/> <xs:element minOccurs="0" maxOccurs="1" ref="xlf:target"/> <xs:element minOccurs="0" maxOccurs="1" ref="xlf:notes"/> <xs:element minOccurs="0" maxOccurs="1" ref="m:matches"/> </xs:sequence> <xs:attribute name="id" use="optional" type="xs:NMTOKEN"/> <xs:attribute name="translate" type="xlf:yesNo" default="yes"/> <xs:attribute name="approved" type="xlf:yesNo" default="no"/> </xs:complexType> </xs:element> Everything seems to be ok. And when I have an XLIFF document like this: <xliff version='2.0' xmlns="urn:oasis:names:tc:xliff:document:2.0" xmlns:m="urn:oasis:names:tc:xliff:matches:2.0" srcLang='en'> <file> <unit id='1'> <segment> <source>text</source> <m:matches> <m:match> <source>text</source> <target>target</target> </m:match> </m:matches> </segment> </unit> </file> </xliff> It seems to work fine and pass validation as well. I've attached the three files. Am I missing something? Cheers, -yves Attachment: MatchModuleTest.zip Description: Zip compressed data

    Attachment(s)

    zip
    MatchModuleTest.zip   2 KB 1 version


  • 7.  RE: [xliff] Extensibility methods

    Posted 05-04-2012 22:00
    Hi Yves, You commented out the declaration of namespaces in your schemas: <!-- <xs:import namespace=" http://www.w3.org/XML/1998/namespace" ; schemaLocation=" http://www.w3.org/2001/xml.xsd"/ > --> If you restore the declaration, you will see that your schemas are not valid. You cannot include the matches module in the core schema and then try to include the core schema in the matches module. Circular references are not valid when working with XML schemas. Regards, Rodolfo -- Rodolfo M. Raya rmraya@maxprograms.com Maxprograms http://www.maxprograms.com >


  • 8.  RE: [xliff] matches as a module

    Posted 05-07-2012 00:18
    Hi Rodolfo, David, all > You commented out the declaration of namespaces > in your schemas: > <!-- <xs:import namespace=" http://www.w3.org/XML/1998/namespace" ; > schemaLocation=" http://www.w3.org/2001/xml.xsd"/ > --> > If you restore the declaration, you will see > that your schemas are not valid. This import is commented out because xml.xsd doesn't need to be imported in the module: None of the attributes defined in xml.xsd is used directly in <matches> or <match>. > You cannot include the matches module in the core schema > and then try to include the core schema in the matches > module. Circular references are not valid when working > with XML schemas. From what I read it seems that circular references are valid. See for example this answer: http://lists.w3.org/Archives/Public/xmlschema-dev/2005May/0061.html: <cite> Yes, it is allowed. You must import a namespace if you refer to any components in that namespace, and it's certainly allowed for A to reference components in B while B refers to components in A. </cite> And it certainly seems to be working: I can validate documents using those three XSD schemes. For example I can change matchQuality to be required and I get the expected error for the test file. And that works with the two validators I've used. Maybe we can verify the schemes with a few XML Schema experts. If it is possible to have <matches> in its own module that would be better: We should follow our own rules on what is core or module. Cheers, -yves


  • 9.  RE: [xliff] matches as a module

    Posted 05-07-2012 10:36
    >


  • 10.  RE: [xliff] matches as a module

    Posted 05-07-2012 11:07
    Good morning Rodolfo, > We use "xml:lang" and "xml:space" attributes > from the "namespace" schema in <source> and <target>. > These two elements appear inside <match>. > We might be able to skip the import in the module > but not in the core schema (you commented it out > in the core schema too) because <source> and <target> > are defined there. I need to check further. Correct: I commented out the wrong import. It should definitely be in core schema. But it doesn't need to be in matches.xsd (as <source> and <target> are not defined there, just referenced). And as long as it's not in both it seems to work. Cheers, -yves


  • 11.  RE: [xliff] matches as a module

    Posted 05-07-2012 15:41
      |   view attached
    Hi All, I believe that the circular references are legal in XML Schema. To test this I built a small infinite recursion test where you can alternate between namespaces. I also included the "xml" namespace and lang attribute to make sure that can be used from both schemas and namespaces at the same time. You need to properly set up catalogs or have tools that have their own catalogs for this to work well. I tested validation using xmllint and XML Validator Buddy and both worked and did proper validation in the nested namespaces. Regards, Fredrik Estreen >

    Attachment(s)

    xml
    test-a.xml   470 B 1 version


  • 12.  RE: [xliff] matches as a module

    Posted 05-07-2012 15:54
    >