Re: Beagle XML/Unix API & Java
D Bera <[email protected]> Wed, 3 Mar 2010 11:53:50 -0500
| Newsgroups | gmane.comp.gnome.dashboard.devel |
|---|---|
| Message-ID | <[email protected]> |
Its too much effort to verify the xsd file :-). But it looks consistent with whatever I remember about the xml structure of hits. I like the idea of generating the parser from the schema - this way future changes (!) could be easily incorporated. I wish we had used a schema based approach for our C# and C API as well ... given that our messages are strictly XML messages. (Ok, I think I remember why we don't use auto-generated classes from XML for C#). - dBera On Mon, Mar 1, 2010 at 6:10 AM, <[email protected]> wrote: > Hi All, > > I have captured the XML message when using the Beagle Web. From this XML,= I tried to write an XML Schema. The XSD file is attached, what do you thin= k about this schema ? Is it well written ? > Then, I used Jaxb to generate the Java Binding Classes (ResponseWrapper.j= ava). > > In SearchManager.java, it's a sample to use the API with Java. > > St=E9phane > > -----Message d'origine----- > De : Joe Shaw [mailto:[email protected]] > Envoy=E9 : lundi 22 f=E9vrier 2010 15:27 > =C0 : zze-BLB JEANJEAN S ext RD-BIZZ-SOP > Cc : [email protected] > Objet : Re: Beagle XML/Unix API > > Hi, > > On Mon, Feb 22, 2010 at 8:57 AM, =A0<[email protected]> wr= ote: >> Is there any documentation about the Beagle XML/Unix API, please ? I >> think it's used by the web user interface. > > There's no documentation for it, sadly. =A0Generally apps should use eith= er the C# classes or one of the C-based language bindings. =A0If you're loo= king to implement a client library yourself, building it on top of the C on= e is the easiest as it is an easily-bindable GObject-based API. > > If you can't go one of these routes for whatever reason, your best bet is= to look at the C code itself. =A0It's fairly simply broken into request an= d response classes, and I think the XML generation in it is pretty clean: > > http://git.gnome.org/browse/beagle/tree/libbeagle/beagle > > The socat tool might also be helpful to you, as you can wedge yourself in= as a man-in-the-middle and watch the traffic going by. > > Joe > > ********************************* > This message and any attachments (the "message") are confidential and int= ended solely for the addressees. > Any unauthorised use or dissemination is prohibited. > Messages are susceptible to alteration. > France Telecom Group shall not be liable for the message if altered, chan= ged or falsified. > If you are not the intended addressee of this message, please cancel it i= mmediately and inform the sender. > ******************************** > > _______________________________________________ > Dashboard-hackers mailing list > [email protected] > http://mail.gnome.org/mailman/listinfo/dashboard-hackers > -- = ----------------------------------------------------- Debajyoti Bera @ http://dtecht.blogspot.com beagle / KDE fan Mandriva / Inspiron-1100 user