0

I'm using org.apache.xml.security.c14n.Canonicalizer which was recommended to me here: Sort xml attributes for pretty print using javax.xml.transform.Transformer. I will need it to run in Java 5 though.. it doesn't seem to work.

Are there any options?

Community
  • 1
  • 1
filippo
  • 5,583
  • 13
  • 50
  • 72

1 Answers1

2

XOM has a Canonicalizer which will do this.

In addition to being a very good general-purpose XML DOM library, it's a much more lightweight solution to canonicalization than your XSLT-based solution.

skaffman
  • 398,947
  • 96
  • 818
  • 769
  • I was my bad after all.. forgot the compiler on java7. All I had to do was build it right. Anyway, this is quite useful and also worked. thanks. – filippo Mar 15 '12 at 16:13