Fixed loads of bugs. It now works. Ready to integrate in assessortool.
[perl4caml.git] / wrappers / pl_Net_Google_Response.ml
diff --git a/wrappers/pl_Net_Google_Response.ml b/wrappers/pl_Net_Google_Response.ml
new file mode 100644 (file)
index 0000000..a134d10
--- /dev/null
@@ -0,0 +1,55 @@
+(* Wrapper around Perl Net::Google::Reponse class.
+ * Copyright (C) 2003 Merjis Ltd.
+ * $Id: pl_Net_Google_Response.ml,v 1.1 2003-10-14 16:05:22 rich Exp $
+ *)
+
+open Perl
+
+class net_google_response sv =
+
+object (self)
+
+  method documentFiltering =
+    bool_of_sv (call_method sv "documentFiltering" [])
+  method searchComments =
+    string_of_sv (call_method sv "searchComments" [])
+  method estimateTotalResultsNumber =
+    int_of_sv (call_method sv "estimateTotalResultsNumber" [])
+  method estimateIsExact =
+    bool_of_sv (call_method sv "estimateIsExact" [])
+  method searchQuery =
+    string_of_sv (call_method sv "searchQuery" [])
+  method startIndex =
+    int_of_sv (call_method sv "startIndex" [])
+  method endIndex =
+    int_of_sv (call_method sv "endIndex" [])
+  method searchTips =
+    string_of_sv (call_method sv "searchTips" [])
+  method directoryCategories =
+    let sv = call_method sv "directoryCategories" [] in
+    let av = deref_array sv in
+    av_map (fun sv -> new net_google_response sv) av
+  method searchTime =
+    float_of_sv (call_method sv "searchTime" [])
+  method toString =
+    string_of_sv (call_method sv "toString" [])
+  method title =
+    string_of_sv (call_method sv "title" [])
+  method url =
+    string_of_sv (call_method sv "URL" [])
+  method snippet =
+    string_of_sv (call_method sv "snippet" [])
+  method cachedSize =
+    string_of_sv (call_method sv "cachedSize" [])
+  method directoryTitle =
+    string_of_sv (call_method sv "directoryTitle" [])
+  method summary =
+    string_of_sv (call_method sv "summary" [])
+  method hostName =
+    string_of_sv (call_method sv "hostName" [])
+
+  (* method directoryCategory *)
+
+end
+
+(* let new_ = ... *)