StringBuilder cannot be resolved to a type?

849 views
Skip to first unread message

julio

unread,
Aug 9, 2007, 3:44:44 AM8/9/07
to Google Web Toolkit
Hi,

like in subject, I get this error when I compile my app that uses
StringBuilder.

Why? StringBuilder cannot be used in GWT (I'm using 1.4RC)?

Thanks,
Julio

darkAngel

unread,
Aug 9, 2007, 3:58:39 AM8/9/07
to Google Web Toolkit
Hi:

I think that StringBuilder is not supported by GWT.

James Abley

unread,
Aug 9, 2007, 4:32:52 AM8/9/07
to Google-We...@googlegroups.com
On 09/08/07, darkAngel <ab.dar...@gmail.com> wrote:
>
> Hi:
>
> I think that StringBuilder is not supported by GWT.

http://code.google.com/webtoolkit/documentation/java.lang.html

Is there any reason you need StringBuilder, rather than StringBuffer?

James

>
>
> >
>

darkAngel

unread,
Aug 9, 2007, 5:40:50 AM8/9/07
to Google Web Toolkit
Hi:

>From The Java Docs (http://java.sun.com/j2se/1.5.0/docs/api/java/lang/
StringBuilder.html):

StringBuilder:

"A mutable sequence of characters. This class provides an API
compatible with StringBuffer, but with no guarantee of
synchronization. This class is designed for use as a drop-in
replacement for StringBuffer in places where the string buffer was
being used by a single thread (as is generally the case)."

Isaac Truett

unread,
Aug 9, 2007, 8:59:21 AM8/9/07
to Google-We...@googlegroups.com
So the answer is no, you don't need it.

GWT doesn't support Java 1.5 anyway. Stick to Java 1.4 classes.

Reply all
Reply to author
Forward
0 new messages