If I create a text file on an operating system that uses the Latin encoding code page ISO/IEC 8859-1. Now if I package the text file as a .war file using the Java jar tool, will it be packaged using the same character encoding as it was on the source Operating System? Or, will it be packaged using some standard encoding such as UTF-8?
Share
Seems like jar takes the bytes from the text file and stores exactly those bytes in the jar/war file without storing any encoding information. This is gleaned from comments on the question as well as the other answers. The answers do not state this clearly, so I am answering my own question. Please correct if I am wrong.