[jdom-interest] Text class

John Interrante jinterra at nycap.rr.com
Sun May 27 14:30:22 PDT 2001


"Brett McLaughlin" <brett at newInstance.com> writes:

>     public void setValue(String stringValue) {
>         value = new StringBuffer(stringValue);
>     }

That method could reduce GC overhead by reusing the existing
StringBuffer:

     public void setValue(String stringValue) {
         value.setLength(0);
         value.append(stringValue);
     }




More information about the jdom-interest mailing list