encoded means in your output-file (f.e. xml) you normally want to escape the values.
So if you have some tag-signs "<" or ">" in the output of the function you don't want them to be put directly to your xml-file, because this can leads to a non-valid xml-file. So with encoding, the output would be for this example "<" or ">" in your file. In some cases you may not want the special characters to be encoded because you want the output to be a tag- then you would choose not to encode them.
For every output-format there are special-characters, which are not allowed to use in the fileformat normally.
Hope that helps.
To the point
Thanks a lot! Much appreciated!
Your explanation is very helpful!