What is the difference between Encoder and MarshalIndent? They both write 
to a stream. When do you use Encoder?

On Tuesday, January 17, 2017 at 9:40:55 PM UTC+2, howar...@gmail.com wrote:
>
> If you actually run that example (click Run below it), you will see it is 
> actually writing out eleven lines of XML.
> If you had two persons, then you would not be marshalling each 
> individually, generally. Instead, you would marshal a slice or array of 
> persons.
>
> See this example:
> https://play.golang.org/p/OS3hgzCBdN
>

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to