OASIS XML Localisation Interchange File Format (XLIFF) TC

 View Only
  • 1.  Question about modules and namespaces

    Posted 08-21-2015 20:34
    Hi all,   I’m curious about modules and namespace declarations. In the test-suite file posted at https://tools.oasis-open.org/version-control/browse/wsvn/xliff/trunk/xliff-20/test-suite/core/in-out/toRewrite1_out.xlf I see the namespace for <validation> declared on the element itself and therefore doesn’t use the “val” prefix:   <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr"> …   <validation xmlns="urn:oasis:names:tc:xliff:validation:2.0">    <rule isPresent="en-ligne"></rule>   </validation> … </xliff>   This is equivalent to:   <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr" xmlns:val="urn:oasis:names:tc:xliff:validation:2.0"> …   <val:validation>    <val:rule isPresent="en-ligne"></val:rule>   </val:validation> … </xliff>   But it is also equivalent to   <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr" xmlns:xyz="urn:oasis:names:tc:xliff:validation:2.0"> …   <xyz:validation>    <xyz:rule isPresent="en-ligne"></xyz:rule>   </xyz:validation> … </xliff>   Is there a reason why modules are prescribed a specific prefix? After all, it is the namespace that makes the actual difference, not the prefix. I just want to make sure I am not missing some nuance here.   Thanks, Ryan    


  • 2.  Re: [xliff] Question about modules and namespaces

    Posted 08-21-2015 21:13
    Ryan, the namespace prefix cannot be prescribed in XML, it's by definition arbitrary and what matters is the declaration, it's just a "model" prefix if u want. What is normatively prescribed is the *fragid* prefix. And the fragid prefix is intentionally the same in each module as the model namespace prefix that is used for that module namespace throughout the spec for consistency and clarity reasons Cheers dF    Dr. David Filip ======================= OASIS XLIFF TC Secretary, Editor, and Liaison Officer  LRC CNGL CSIS University of Limerick, Ireland telephone: +353-6120-2781 cellphone: +353-86-0222-158 facsimile: +353-6120-2734 http://www.cngl.ie/profile/?i=452 mailto:  david.filip@ul.ie On Fri, Aug 21, 2015 at 9:34 PM, Ryan King < ryanki@microsoft.com > wrote: Hi all,   I’m curious about modules and namespace declarations. In the test-suite file posted at https://tools.oasis-open.org/version-control/browse/wsvn/xliff/trunk/xliff-20/test-suite/core/in-out/toRewrite1_out.xlf I see the namespace for <validation> declared on the element itself and therefore doesn’t use the “val” prefix:   <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr"> …   <validation xmlns="urn:oasis:names:tc:xliff:validation:2.0">    <rule isPresent="en-ligne"></rule>   </validation> … </xliff>   This is equivalent to:   <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr" xmlns:val="urn:oasis:names:tc:xliff:validation:2.0"> …   <val:validation>    <val:rule isPresent="en-ligne"></val:rule>   </val:validation> … </xliff>   But it is also equivalent to   <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr" xmlns:xyz="urn:oasis:names:tc:xliff:validation:2.0"> …   <xyz:validation>    <xyz:rule isPresent="en-ligne"></xyz:rule>   </xyz:validation> … </xliff>   Is there a reason why modules are prescribed a specific prefix? After all, it is the namespace that makes the actual difference, not the prefix. I just want to make sure I am not missing some nuance here.   Thanks, Ryan    


  • 3.  RE: [xliff] Question about modules and namespaces

    Posted 08-21-2015 21:24




    I agree. I think identifying the prefixes as best practice makes sense, in terms of human readability, interoperability between non-XML based agents (gasp).
     
    But I think making it a conformance requirement (which nobody has proposed) would be heavy-handed.
     
    From: xliff@lists.oasis-open.org [mailto:xliff@lists.oasis-open.org]
    On Behalf Of Dr. David Filip
    Sent: Friday, August 21, 2015 2:12 PM
    To: Ryan King
    Cc: xliff@lists.oasis-open.org
    Subject: Re: [xliff] Question about modules and namespaces
     

    Ryan, the namespace prefix cannot be prescribed in XML, it's by definition arbitrary and what matters is the declaration, it's just a "model" prefix if u want.

    What is normatively prescribed is the *fragid* prefix. And the fragid prefix is intentionally the same in each module as the model namespace prefix that is used for that module namespace throughout the spec for consistency and clarity reasons


    Cheers


    dF   










    Dr. David Filip







    =======================

    OASIS XLIFF TC Secretary, Editor, and Liaison Officer 


    LRC CNGL CSIS


    University of Limerick, Ireland


    telephone: +353-6120-2781


    cellphone: +353-86-0222-158


    facsimile: +353-6120-2734


    http://www.cngl.ie/profile/?i=452


    mailto:  david.filip@ul.ie









     

    On Fri, Aug 21, 2015 at 9:34 PM, Ryan King < ryanki@microsoft.com > wrote:


    Hi all,
     
    I’m curious about modules and namespace declarations. In the test-suite file posted at
    https://tools.oasis-open.org/version-control/browse/wsvn/xliff/trunk/xliff-20/test-suite/core/in-out/toRewrite1_out.xlf
    I see the namespace for <validation> declared on the element itself and therefore doesn’t use the “val” prefix:
     
    <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr">

      <validation xmlns="urn:oasis:names:tc:xliff:validation:2.0">
       <rule isPresent="en-ligne"></rule>
      </validation>

    </xliff>
     
    This is equivalent to:
     
    <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr" xmlns:val="urn:oasis:names:tc:xliff:validation:2.0">

      <val:validation>
       <val:rule isPresent="en-ligne"></val:rule>
      </val:validation>

    </xliff>
     
    But it is also equivalent to

     
    <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr" xmlns:xyz="urn:oasis:names:tc:xliff:validation:2.0">

      <xyz:validation>
       <xyz:rule isPresent="en-ligne"></xyz:rule>
      </xyz:validation>

    </xliff>
     
    Is there a reason why modules are prescribed a specific prefix? After all, it is the namespace that makes the actual difference, not the prefix. I just
    want to make sure I am not missing some nuance here.
     
    Thanks,
    Ryan  
     



     







  • 4.  RE: [xliff] Question about modules and namespaces

    Posted 08-21-2015 23:25




    Agreed, as well, and that is whay I queried to make sure there wasn’t some reason I missed. Thanks all!
     


    From: Schnabel, Bryan S [mailto:bryan.s.schnabel@tektronix.com]

    Sent: Friday, August 21, 2015 2:24 PM
    To: Dr. David Filip <David.Filip@ul.ie>; Ryan King <ryanki@microsoft.com>
    Cc: xliff@lists.oasis-open.org
    Subject: RE: [xliff] Question about modules and namespaces


     
    I agree. I think identifying the prefixes as best practice makes sense, in terms of human readability, interoperability between non-XML based agents (gasp).
     
    But I think making it a conformance requirement (which nobody has proposed) would be heavy-handed.
     
    From:
    xliff@lists.oasis-open.org [ mailto:xliff@lists.oasis-open.org ]
    On Behalf Of Dr. David Filip
    Sent: Friday, August 21, 2015 2:12 PM
    To: Ryan King
    Cc: xliff@lists.oasis-open.org
    Subject: Re: [xliff] Question about modules and namespaces
     

    Ryan, the namespace prefix cannot be prescribed in XML, it's by definition arbitrary and what matters is the declaration, it's just a "model" prefix if u want.

    What is normatively prescribed is the *fragid* prefix. And the fragid prefix is intentionally the same in each module as the model namespace prefix that is used for that module namespace throughout the spec for consistency and clarity reasons


    Cheers


    dF   










    Dr. David Filip







    =======================

    OASIS XLIFF TC Secretary, Editor, and Liaison Officer 


    LRC CNGL CSIS


    University of Limerick, Ireland


    telephone: +353-6120-2781


    cellphone: +353-86-0222-158


    facsimile: +353-6120-2734


    http://www.cngl.ie/profile/?i=452


    mailto:  david.filip@ul.ie









     

    On Fri, Aug 21, 2015 at 9:34 PM, Ryan King < ryanki@microsoft.com > wrote:


    Hi all,
     
    I’m curious about modules and namespace declarations. In the test-suite file posted at
    https://tools.oasis-open.org/version-control/browse/wsvn/xliff/trunk/xliff-20/test-suite/core/in-out/toRewrite1_out.xlf
    I see the namespace for <validation> declared on the element itself and therefore doesn’t use the “val” prefix:
     
    <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr">

      <validation xmlns="urn:oasis:names:tc:xliff:validation:2.0">
       <rule isPresent="en-ligne"></rule>
      </validation>

    </xliff>
     
    This is equivalent to:
     
    <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr" xmlns:val="urn:oasis:names:tc:xliff:validation:2.0">

      <val:validation>
       <val:rule isPresent="en-ligne"></val:rule>
      </val:validation>

    </xliff>
     
    But it is also equivalent to

     
    <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr" xmlns:xyz="urn:oasis:names:tc:xliff:validation:2.0">

      <xyz:validation>
       <xyz:rule isPresent="en-ligne"></xyz:rule>
      </xyz:validation>

    </xliff>
     
    Is there a reason why modules are prescribed a specific prefix? After all, it is the namespace that makes the actual difference, not the prefix. I just
    want to make sure I am not missing some nuance here.
     
    Thanks,
    Ryan  
     



     







  • 5.  RE: [xliff] Question about modules and namespaces

    Posted 08-21-2015 21:37




    Thanks David, that clears it up for me. So it is possible to do this:
     
    <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr" xmlns:xyz="urn:oasis:names:tc:xliff:validation:2.0">

      <xyz:validation>
       <xyz:rule isPresent="en-ligne"></xyz:rule>
      </xyz:validation>

    </xliff>
     
    As long as I use “val” as the fragment identifier prefix.
     
    Thanks,
    Ryan
     
    From: xliff@lists.oasis-open.org [mailto:xliff@lists.oasis-open.org]
    On Behalf Of Dr. David Filip
    Sent: Friday, August 21, 2015 2:12 PM
    To: Ryan King <ryanki@microsoft.com>
    Cc: xliff@lists.oasis-open.org
    Subject: Re: [xliff] Question about modules and namespaces
     

    Ryan, the namespace prefix cannot be prescribed in XML, it's by definition arbitrary and what matters is the declaration, it's just a "model" prefix if u want.

    What is normatively prescribed is the *fragid* prefix. And the fragid prefix is intentionally the same in each module as the model namespace prefix that is used for that module namespace throughout the spec for consistency and clarity reasons


    Cheers


    dF   










    Dr. David Filip







    =======================

    OASIS XLIFF TC Secretary, Editor, and Liaison Officer 


    LRC CNGL CSIS


    University of Limerick, Ireland


    telephone: +353-6120-2781


    cellphone: +353-86-0222-158


    facsimile: +353-6120-2734


    http://www.cngl.ie/profile/?i=452


    mailto:  david.filip@ul.ie









     

    On Fri, Aug 21, 2015 at 9:34 PM, Ryan King < ryanki@microsoft.com > wrote:



    Hi all,
     
    I’m curious about modules and namespace declarations. In the test-suite file posted at
    https://tools.oasis-open.org/version-control/browse/wsvn/xliff/trunk/xliff-20/test-suite/core/in-out/toRewrite1_out.xlf
    I see the namespace for <validation> declared on the element itself and therefore doesn’t use the “val” prefix:
     
    <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr">

      <validation xmlns="urn:oasis:names:tc:xliff:validation:2.0">
       <rule isPresent="en-ligne"></rule>
      </validation>

    </xliff>
     
    This is equivalent to:
     
    <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr" xmlns:val="urn:oasis:names:tc:xliff:validation:2.0">

      <val:validation>
       <val:rule isPresent="en-ligne"></val:rule>
      </val:validation>

    </xliff>
     
    But it is also equivalent to

     
    <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr" xmlns:xyz="urn:oasis:names:tc:xliff:validation:2.0">

      <xyz:validation>
       <xyz:rule isPresent="en-ligne"></xyz:rule>
      </xyz:validation>

    </xliff>
     
    Is there a reason why modules are prescribed a specific prefix? After all, it is the namespace that makes the actual difference, not the prefix. I just
    want to make sure I am not missing some nuance here.
     
    Thanks,
    Ryan  
     




     







  • 6.  Re: [xliff] Question about modules and namespaces

    Posted 08-21-2015 22:12
    Exactly, u can declare arbitrary namespace prefixes, the identity of the namespace is given by the URN in our case (or an URI in most other cases) Agents need to lookup the namespace identity anyways, even if u used the model prefix. But the fragid prefix is non-negotiable.. Cheers dF  Dr. David Filip ======================= OASIS XLIFF TC Secretary, Editor, and Liaison Officer  LRC CNGL CSIS University of Limerick, Ireland telephone: +353-6120-2781 cellphone: +353-86-0222-158 facsimile: +353-6120-2734 http://www.cngl.ie/profile/?i=452 mailto:  david.filip@ul.ie On Fri, Aug 21, 2015 at 10:37 PM, Ryan King < ryanki@microsoft.com > wrote: Thanks David, that clears it up for me. So it is possible to do this:   <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr" xmlns:xyz="urn:oasis:names:tc:xliff:validation:2.0"> …   <xyz:validation>    <xyz:rule isPresent="en-ligne"></xyz:rule>   </xyz:validation> … </xliff>   As long as I use “val” as the fragment identifier prefix.   Thanks, Ryan   From: xliff@lists.oasis-open.org [mailto: xliff@lists.oasis-open.org ] On Behalf Of Dr. David Filip Sent: Friday, August 21, 2015 2:12 PM To: Ryan King < ryanki@microsoft.com > Cc: xliff@lists.oasis-open.org Subject: Re: [xliff] Question about modules and namespaces   Ryan, the namespace prefix cannot be prescribed in XML, it's by definition arbitrary and what matters is the declaration, it's just a "model" prefix if u want. What is normatively prescribed is the *fragid* prefix. And the fragid prefix is intentionally the same in each module as the model namespace prefix that is used for that module namespace throughout the spec for consistency and clarity reasons Cheers dF    Dr. David Filip ======================= OASIS XLIFF TC Secretary, Editor, and Liaison Officer  LRC CNGL CSIS University of Limerick, Ireland telephone: +353-6120-2781 cellphone: +353-86-0222-158 facsimile: +353-6120-2734 http://www.cngl.ie/profile/?i=452 mailto:  david.filip@ul.ie   On Fri, Aug 21, 2015 at 9:34 PM, Ryan King < ryanki@microsoft.com > wrote: Hi all,   I’m curious about modules and namespace declarations. In the test-suite file posted at https://tools.oasis-open.org/version-control/browse/wsvn/xliff/trunk/xliff-20/test-suite/core/in-out/toRewrite1_out.xlf I see the namespace for <validation> declared on the element itself and therefore doesn’t use the “val” prefix:   <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr"> …   <validation xmlns="urn:oasis:names:tc:xliff:validation:2.0">    <rule isPresent="en-ligne"></rule>   </validation> … </xliff>   This is equivalent to:   <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr" xmlns:val="urn:oasis:names:tc:xliff:validation:2.0"> …   <val:validation>    <val:rule isPresent="en-ligne"></val:rule>   </val:validation> … </xliff>   But it is also equivalent to   <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr" xmlns:xyz="urn:oasis:names:tc:xliff:validation:2.0"> …   <xyz:validation>    <xyz:rule isPresent="en-ligne"></xyz:rule>   </xyz:validation> … </xliff>   Is there a reason why modules are prescribed a specific prefix? After all, it is the namespace that makes the actual difference, not the prefix. I just want to make sure I am not missing some nuance here.   Thanks, Ryan      


  • 7.  RE: [xliff] Question about modules and namespaces

    Posted 08-21-2015 23:23




    Thanks again for the clarity.
     
    From: Dr. David Filip [mailto:David.Filip@ul.ie]

    Sent: Friday, August 21, 2015 3:11 PM
    To: Ryan King <ryanki@microsoft.com>
    Cc: Dr. David Filip <David.Filip@ul.ie>; xliff@lists.oasis-open.org
    Subject: Re: [xliff] Question about modules and namespaces
     

    Exactly, u can declare arbitrary namespace prefixes, the identity of the namespace is given by the URN in our case (or an URI in most other cases)

    Agents need to lookup the namespace identity anyways, even if u used the model prefix.


     


    But the fragid prefix is non-negotiable..


    Cheers


    dF 










    Dr. David Filip







    =======================

    OASIS XLIFF TC Secretary, Editor, and Liaison Officer 


    LRC CNGL CSIS


    University of Limerick, Ireland


    telephone: +353-6120-2781


    cellphone: +353-86-0222-158


    facsimile: +353-6120-2734


    http://www.cngl.ie/profile/?i=452


    mailto:  david.filip@ul.ie









     

    On Fri, Aug 21, 2015 at 10:37 PM, Ryan King < ryanki@microsoft.com > wrote:



    Thanks David, that clears it up for me. So it is possible to do this:
     
    <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr" xmlns:xyz="urn:oasis:names:tc:xliff:validation:2.0">

      <xyz:validation>
       <xyz:rule isPresent="en-ligne"></xyz:rule>
      </xyz:validation>

    </xliff>
     
    As long as I use “val” as the fragment identifier prefix.
     
    Thanks,
    Ryan
     
    From:
    xliff@lists.oasis-open.org [mailto: xliff@lists.oasis-open.org ]
    On Behalf Of Dr. David Filip
    Sent: Friday, August 21, 2015 2:12 PM
    To: Ryan King < ryanki@microsoft.com >
    Cc: xliff@lists.oasis-open.org
    Subject: Re: [xliff] Question about modules and namespaces
     

    Ryan, the namespace prefix cannot be prescribed in XML, it's by definition arbitrary and what matters is the declaration, it's just a "model" prefix if u want.



    What is normatively prescribed is the *fragid* prefix. And the fragid prefix is intentionally the same in each module as the model namespace prefix that is used for that module
    namespace throughout the spec for consistency and clarity reasons


    Cheers


    dF   














    Dr. David Filip







    =======================

    OASIS XLIFF TC Secretary, Editor, and Liaison Officer 


    LRC CNGL CSIS


    University of Limerick, Ireland


    telephone: +353-6120-2781


    cellphone: +353-86-0222-158


    facsimile: +353-6120-2734


    http://www.cngl.ie/profile/?i=452


    mailto:  david.filip@ul.ie









     

    On Fri, Aug 21, 2015 at 9:34 PM, Ryan King < ryanki@microsoft.com > wrote:



    Hi all,
     
    I’m curious about modules and namespace declarations. In the test-suite file posted at
    https://tools.oasis-open.org/version-control/browse/wsvn/xliff/trunk/xliff-20/test-suite/core/in-out/toRewrite1_out.xlf
    I see the namespace for <validation> declared on the element itself and therefore doesn’t use the “val” prefix:
     
    <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr">

      <validation xmlns="urn:oasis:names:tc:xliff:validation:2.0">
       <rule isPresent="en-ligne"></rule>
      </validation>

    </xliff>
     
    This is equivalent to:
     
    <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr" xmlns:val="urn:oasis:names:tc:xliff:validation:2.0">

      <val:validation>
       <val:rule isPresent="en-ligne"></val:rule>
      </val:validation>

    </xliff>
     
    But it is also equivalent to

     
    <xliff xmlns="urn:oasis:names:tc:xliff:document:2.0" version="2.0" srcLang="en" trgLang="fr" xmlns:xyz="urn:oasis:names:tc:xliff:validation:2.0">

      <xyz:validation>
       <xyz:rule isPresent="en-ligne"></xyz:rule>
      </xyz:validation>

    </xliff>
     
    Is there a reason why modules are prescribed a specific prefix? After all, it is the namespace that makes the actual difference, not the prefix. I just
    want to make sure I am not missing some nuance here.
     
    Thanks,
    Ryan