Return-Path: Delivered-To: apmail-jakarta-commons-dev-archive@www.apache.org Received: (qmail 41739 invoked from network); 25 Apr 2007 22:38:46 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 25 Apr 2007 22:38:45 -0000 Received: (qmail 54536 invoked by uid 500); 25 Apr 2007 22:38:45 -0000 Delivered-To: apmail-jakarta-commons-dev-archive@jakarta.apache.org Received: (qmail 54476 invoked by uid 500); 25 Apr 2007 22:38:45 -0000 Mailing-List: contact commons-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Jakarta Commons Developers List" Reply-To: "Jakarta Commons Developers List" Delivered-To: mailing list commons-dev@jakarta.apache.org Received: (qmail 54204 invoked by uid 99); 25 Apr 2007 22:38:45 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 25 Apr 2007 15:38:43 -0700 X-ASF-Spam-Status: No, hits=-100.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 25 Apr 2007 15:38:36 -0700 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id EBBC6714082 for ; Wed, 25 Apr 2007 15:38:15 -0700 (PDT) Message-ID: <4044184.1177540695963.JavaMail.jira@brutus> Date: Wed, 25 Apr 2007 15:38:15 -0700 (PDT) From: "Emmanuel Bourg (JIRA)" To: commons-dev@jakarta.apache.org Subject: [jira] Updated: (CONFIGURATION-41) [configuration] Output format of FileConfiguration classes MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/CONFIGURATION-41?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Emmanuel Bourg updated CONFIGURATION-41: ---------------------------------------- Fix Version/s: 1.2 > [configuration] Output format of FileConfiguration classes > ---------------------------------------------------------- > > Key: CONFIGURATION-41 > URL: https://issues.apache.org/jira/browse/CONFIGURATION-41 > Project: Commons Configuration > Issue Type: Bug > Affects Versions: 1.1 > Environment: Operating System: Windows 2000 > Platform: Other > Reporter: Kay Doebl > Fix For: 1.2 > > Attachments: properties_lineseparator.patch, XML_encoding.patch > > > I am using Commons Configuration 1.1. > Saving 'FielConfiguration's the configuration files will be overwritten every time. > Bad if you have formatted them with descriptions and comments ... but this is > not so important. > Not so good is, that in the class: > PropertiesConfiguration: > '\n' is used as "line separator" and not the "System.getProperty("line.separator")". > So, on Windows systems the configuration files are badly readable. > XMLConfiguration: > The encoding is not looped though to the encoding in the XML head declaration. > Every time "UTF-8" is set () > I would prefer that my encoding (setEncoding()) is reflected in the XML document. > Is there a reason that it is implemented like you do? > Attached are patches which would resolve the problems (if you want): > PropertiesConfiguration.java: > properties_lineseparator.patch > 136a137,138 > > private static final String lineSeparator = > System.getProperty("line.separator"); > > > 344c346 > < out.write("\n"); > --- > > out.write(lineSeparator); > 349c351 > < out.write("\n"); > --- > > out.write(lineSeparator); > 486c488 > < write('\n'); > --- > > write(lineSeparator); > 511c513 > < write("# " + comment + "\n"); > --- > > write("# " + comment + lineSeparator); > XMLConfiguration.java: > XML_encoding.patch > 446a447 > > transformer.setOutputProperty(OutputKeys.ENCODING, getEncoding()); -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org For additional commands, e-mail: commons-dev-help@jakarta.apache.org