Canonicalization Rules for Interchange Format

The goal of the interchange format is to reduce the problem of comparing 
component models to comparing XML infosets. Many properties of the 
component model are sets with no order. We therefore need to specify the 
order rules to make infoset comparison work. Element order is significant 
in infosets.

I've implemented the following in the Woden writer. Please review for 
completeness and otherwise.

Assume the character representation is Unicode and that we don't care 
about canonicalizing the characters since the tests are applied to the 
same document, i.e. we are comparing two processors acting on the same 
document. Assume the processors treat the characters verbatim.

When sorting by a QName, sort by QName.{namespaceName}, then by 
QName.{localName}

Sort IRIs and NCNames like strings.

1. Description.{interfaces} - sort by Interface.{name}

2. Description.{bindings} - sort by Binding.{name}

3.Description.{services} - sort by Service.{name}

4. Description.{elementDeclarations} - sort by ElementDeclaration.{name}

5. Description.{typeDefinitions} - sort by TypeDefinition.{name}

6. Interface.{extendedInterfaces} - sort by Interface.{name}

7. Interface.{interfaceFaults} - sort by InterfaceFault.{name}

8. Interface.{operations} - sort by InterfaceOperation.{name}

9. InterfaceOperation.{interfaceMessageReferences} - sort by 
InterfaceMessageReference.{message label}

10. InterfaceOperation.{interfaceFaultReferences} - sort by 
InterfaceFaultReference.{interface fault}.{name}, then by 
InterfaceFaultReference.{message label}

11. Binding.{bindingFaults} - sorty by 
BindingFault.{interfaceFault}.{name}

12. Binding.{operations} - sort by 
BindingOperation.{interfaceOperation}.{name}

13. BindingOperation.{bindingMessageReferences} - sort by 
BindingMessageReference.{interface message reference}.{name}

14. BindingOperation.{bindingFaultReferences} - sort by 
BindingFaultReference.{interface fault reference}.{interface 
fault}.{name}, then by BindingFaultReference.{interface fault 
reference}.{message label}

15. Service.{endpoints} - sort by Endpoint.{name}

16. *.{features} - sort by Feature.{ref}

17. *.{properties} - sort by Property.{ref}

Arthur Ryman,
IBM Software Group, Rational Division

blog: http://ryman.eclipsedevelopersjournal.com/
phone: +1-905-413-3077, TL 969-3077
assistant: +1-905-413-2411, TL 969-2411
fax: +1-905-413-4920, TL 969-4920
mobile: +1-416-939-5063, text: 4169395063@fido.ca

Received on Tuesday, 18 April 2006 16:37:09 UTC