我有来自Ruby的calabash-android的输出
[{"class"=>"com.android.internal.policy.impl.PhoneWindow$DecorView", "tag"=>nil, "description"=>"com.android.internal.policy.impl.PhoneWindow$DecorView{2d9e9f7f V.E..... R....... 0,0-768,1280}", "id"=>nil, "visible"=>true, "rect"=>{"height"=>1280, "width"=>768, "y"=>0, "x"=>0, "center_x"=>384, "center_y"=>640}, "enabled"=>true, "contentDescription"=>nil}, {"class"=>"android.widget.LinearLayout", "tag"=>nil, "description"=>"android.widget.LinearLayout{11a51d5c V.E..... ........ 0,0-768,1280}", "id"=>nil, "visible"=>true, "rect"=>{"height"=>1280, "width"=>768, "y"=>0, "x"=>0, "center_x"=>384, "center_y"=>640}, "enabled"=>true, "contentDescription"=>nil}, {"class"=>"android.widget.FrameLayout", "tag"=>nil, "description"=>"android.widget.FrameLayout{2367b865 V.E..... ........ 0,0-768,1280}", "id"=>nil, "visible"=>true, "rect"=>{"height"=>1280, "width"=>768, "y"=>0, "x"=>0, "center_x"=>384, "center_y"=>640}, "enabled"=>true, "contentDescription"=>nil}]
我想使用JSON进行解析。我有类似的挑战,而不是:它有=>
目前,我已经使用字符串操作实现了它。
谢谢, 阿比吉特·希拉尔(Abhijit Shelar)