Hello ,
the last weeks i have started using Gwt technology and i have to admit
that is fascinating!! because of lack of examples, i have some
questions.

first of all , i m facing a compilation error.

I did include  <inherits name="com.google.gwt.http.HTTP" />
in the gwt config file but when i m trying to compile i get

Removing units with errors
   [ERROR] Errors in 'file:/home/tower/Book/G-example/src/org/example/
client/ajson.java'
      [ERROR] Line 45: RequestBuilder cannot be resolved to a type
      [ERROR] Line 45: RequestBuilder cannot be resolved to a type
      [ERROR] Line 45: RequestBuilder cannot be resolved
      [ERROR] Line 49: RequestException cannot be resolved to a type
      [ERROR] Line 54: RequestCallback cannot be resolved to a type
      [ERROR] Line 56: Request cannot be resolved to a type
      [ERROR] Line 61: Request cannot be resolved to a type
      [ERROR] Line 61: Response cannot be resolved to a type


Secondly , i m trying to make an example reading a json file. If i put
the json file in the same folder as ./example-shell then i do that:
RequestBuilder builder = new
RequestBuilder(RequestBuilder.POST,GWT.getModuleBaseURL() +
"file.json");

otherwise
i just put the url ( located in a local server ? )

    RequestBuilder builder = new RequestBuilder(RequestBuilder.GET,
url);

    try {
      Request response = builder.sendRequest(null, new
RequestCallback() {
        public void onError(Request request, Throwable exception) {
          // Code omitted for clarity
        }

        public void onResponseReceived(Request request, Response
response) {
          JSONArray results;
      results = maketree(response.getText());
        }
      });
    } catch (RequestException e) {
      // Code omitted for clarity
    }

Is this algorithm correct???
also is there any function like maketree that reads the object and
makes it in a tree format ??
ty in advance.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to