How to parse the response of GWT app?

75 views
Skip to first unread message

redice

unread,
Jun 24, 2011, 4:44:31 AM6/24/11
to Google Web Toolkit
I want to parse the response of GWT app like following:

//
OK[41,40,0,2,39,38,37,0,36,0,4,1,4,35,19,1,3,34,19,18,1,17,1,-17,33,0,710,1,0,4,0,28,12,11,0,32,31,8,7,30,19,18,1,17,1,2,16,29,0,700,1,0,4,1,28,12,11,0,27,26,8,7,25,19,18,1,17,1,-8,24,0,500,1,150,23,1,22,12,11,0,22,21,8,7,20,19,18,1,17,1,1,16,15,0,410,1,150,14,1,13,12,11,0,10,9,8,7,4,3,1,6,5,0,4,0,0,0,3,2,1,
["gov.egov.erule.regs.shared.action.LoadDocumentDetailResult/
3665673162","gov.egov.erule.regs.shared.models.DocumentDetailModel/
1210760895","java.util.ArrayList/3821976829","","FDA-2010-
P-0532","gov.egov.erule.regs.shared.models.DocketType/
1323825229","gov.egov.erule.regs.shared.models.MetadataValueModel/
1270413309","gov.egov.erule.regs.shared.models.MetadataModel/
1441296737","Document Subtype","doc_sub_type","SUPPORTING & RELATED
MATERIALS","1","doc_type","dk_subType_v","Used to further define the
type of document","gov.egov.erule.regs.shared.models.MetadataModel
$UiControlType/4187881057","com.extjs.gxt.ui.client.data.RpcMap/
3441186752","value","java.lang.String/2004016611","CP-Citizen Petition
(Supporting & Related
Materials)","Status","doc_status","doc_status_v","The current status
of the document","Posted","Received
Date","receive_date","doc_primary_dates","The date the agency received
or created the document","October 04 2010, at 12:00 AM Eastern
Daylight Time ","Date Posted","fr_publish_date","Date the document is
posted to Regulations.gov","November 10 2010, at 12:00 AM Eastern
Standard Time ","pdf","[Ljava.lang.String;/2600011424","FDA","FDA-2010-
P-0532-0005","gov.egov.erule.regs.shared.models.DocumentType/
2460330259","0900006480b68632","Attachment 4 - \"Information Regarding
Cigarettes with Characterizing Flavors Form 3734\" - [BBK Tobacco &
Foods, LLP, (Levin Ginsburg Attorneys at Law) - Citizen Petition] "],
0,7]


Can you help me?

David Chandler

unread,
Jun 24, 2011, 2:06:12 PM6/24/11
to google-we...@googlegroups.com
Sure, for a percentage of the settlement.

/dmc


--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To post to this group, send email to google-we...@googlegroups.com.
To unsubscribe from this group, send email to google-web-tool...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.




--
David Chandler
Developer Programs Engineer, Google Web Toolkit
w: http://code.google.com/
b: http://googlewebtoolkit.blogspot.com/
t: @googledevtools

Jeff Larsen

unread,
Jun 24, 2011, 2:16:21 PM6/24/11
to google-we...@googlegroups.com
Careful David, 0 is a percent ;)

Qi Peng

unread,
Jun 26, 2011, 12:28:58 AM6/26/11
to google-we...@googlegroups.com
hi David,

I want to get your help.

I want to know how to parse the response data(like bellow) of GWT app.

Sample data:

//OK[41,40,0,2,39,38,37,0,36,0,4,1,4,35,19,1,3,34,19,18,1,17,1,-17,33,0,710,1,0,4,0,28,12,11,0,32,31,8,7,30,19,18,1,17,1,2,16,29,0,700,1,0,4,1,28,12,11,0,27,26,8,7,25,19,18,1,17,1,-8,24,0,500,1,150,23,1,22,12,11,0,22,21,8,7,20,19,18,1,17,1,1,16,15,0,410,1,150,14,1,13,12,11,0,10,9,8,7,4,3,1,6,5,0,4,0,0,0,3,2,1,["gov.egov.erule.regs.shared.action.LoadDocumentDetailResult/3665673162","gov.egov.erule.regs.shared.models.DocumentDetailModel/1210760895","java.util.ArrayList/3821976829","","FDA-2010-P-0532","gov.egov.erule.regs.shared.models.DocketType/1323825229","gov.egov.erule.regs.shared.models.MetadataValueModel/1270413309","gov.egov.erule.regs.shared.models.MetadataModel/1441296737","Document Subtype","doc_sub_type","SUPPORTING & RELATED MATERIALS","1","doc_type","dk_subType_v","Used to further define the type of document","gov.egov.erule.regs.shared.models.MetadataModel$UiControlType/4187881057","com.extjs.gxt.ui.client.data.RpcMap/3441186752","value","java.lang.String/2004016611","CP-Citizen Petition (Supporting & Related Materials)","Status","doc_status","doc_status_v","The current status of the document","Posted","Received Date","receive_date","doc_primary_dates","The date the agency received or created the document","October 04 2010, at 12:00 AM Eastern Daylight Time ","Date Posted","fr_publish_date","Date the document is posted to Regulations.gov","November 10 2010, at 12:00 AM Eastern Standard Time ","pdf","[Ljava.lang.String;/2600011424","FDA","FDA-2010-P-0532-0005","gov.egov.erule.regs.shared.models.DocumentType/2460330259","0900006480b68632","Attachment 4 - \"Information Regarding Cigarettes with Characterizing Flavors Form 3734\" - [BBK Tobacco & Foods, LLP, (Levin Ginsburg Attorneys at Law) - Citizen Petition] "],0,7]

Can you tell me how to deserialize the data?

I want to scrape some information from it, e.g. "Status" (in this case, shoule be "Posted").

Thanks a lot.


From Qi

Plumo

unread,
Jun 27, 2011, 11:55:52 AM6/27/11
to google-we...@googlegroups.com
How about split the response string by comma "," and extract the required indices. 
Reply all
Reply to author
Forward
0 new messages