omitting prolog when serializing using asString

12 views
Skip to first unread message

Michael Feldkamp

unread,
Feb 27, 2016, 6:55:49 AM2/27/16
to scales-xml
Hello - 

First off, very nice library. 

My question is, what is the proper way to write an XML object without including the prolog (<?xml ...)?

Looking through the code, I can't really see a clean way to do this, but I'm probably missing something. Do I have to subclass SimpleSerializerFactory and SimpleSerializer, setting the xmlDeclaration member to return None? Is there an easier / more straightforward way?

Sorry if this is a trivial question, I'm fairly new to Scala and Scales.

Thanks,
Mike

Chris Twiner

unread,
Feb 27, 2016, 7:08:22 AM2/27/16
to scale...@googlegroups.com

Hi Mike,

You can do as described but also write your own serialise function, there isn't much to it, but I'd personally go down the serializer route.

Can I ask why you want to do that?

Cheers,
Chris

--
You received this message because you are subscribed to the Google Groups "scales-xml" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scales-xml+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages