Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

[OT] Java equivalent of WWW::Mechanize?

by gjb (Vicar)
on Jul 06, 2004 at 13:39 UTC ( [id://372101]=perlquestion: print w/replies, xml ) Need Help??

gjb has asked for the wisdom of the Perl Monks concerning the following question:

I realize this is very much off-topic, so feel free to ignore. However, since there are many developers of web applications in the community who work with both Perl and Java I thought I might ask here anyway. I googled and found a number of things, but it's hard to say what some projects are worth.

Does anyone know of an equivalent of WWW::Mechanize for Java? And more importantly, any experiences with it?

Thanks in advance, -gjb-

  • Comment on [OT] Java equivalent of WWW::Mechanize?

Replies are listed 'Best First'.
Re: [OT] Java equivalent of WWW::Mechanize?
by Tomte (Priest) on Jul 06, 2004 at 14:44 UTC

    Have a look if HttpUnit is suitable in your situation; I have only little experience with it, I've written a few Unit-Tests for our CMS while testing it for suitability in our situation ;P. It's fully-fledged (Cookies, JavaScript, ...) and easy to work with, but it's java and employs therefore a kind of flamboyant interface...

    regards,
    tomte


    An intellectual is someone whose mind watches itself.
    -- Albert Camus

      From a cursory scan it seems that the functionality and ease of use (barring Javaisms of course ;) is very similar to that of WWW::Mechanize. It seems HttpUnit would do very nicely for this project.

      Thanks for the excellent suggestion, -gjb-

Re: [OT] Java equivalent of WWW::Mechanize?
by arden (Curate) on Jul 06, 2004 at 14:15 UTC
    You could post the question (and be on-topic) at http://www.javajunkies.org and hope for a response. The site has nowhere near the large following this one enjoys, but every site has to start somewhere!

    - - arden.

      Thanks for your suggestion. As a matter of fact I happen to be a JavaJunkie and already posted my question there prior to turning to PerlMonks. Unfortunately as you mention the JavaJunkies community is not that large, so I decided to cross post anyway.

      Thanks, -gjb-

Re: [OT] Java equivalent of WWW::Mechanize?
by knoebi (Friar) on Jul 07, 2004 at 11:54 UTC
    I suggest you try out Canoo's WebTest. It offers also a high-level interface (as WWW::Mechanize) and uses http-unit for the actual tests (like WWW::Mechanize uses lwp).
    It has very good reporting features and there is also a proxy for recording (like HTTP::Recorder).

    I installed it last year and i'am pretty happy with it. I use it for automatic testing of dynamic web-sites. xpath is really great! but i wan't to switch to HTTP::Recorder/WWW::Mechanize because it's a pure perl solution.

    ciao
    knoebi

      Very interesting link, but not really what I'm looking for in this project. As far as I can see interaction is specified using XML files rather than an API. The purpose is to communicate with a webserver and manipulate the information that is returned from within a Java program (this is just part of a larger program).

      Thanks, -gjb-

Re: [OT] Java equivalent of WWW::Mechanize?
by gmpassos (Priest) on Jul 07, 2004 at 07:58 UTC

      The only reason to avoid Perl is that the student who is to do this project might not be familiar with it and has only a limited amount of time to complete it. Futhermore, the result is supposed to be used in real world applications and hence should be as easy and simple to maintain as possible. Adding an extra layer of complexity won't improve that.

      So thanks for the suggestion which is interesting, but I don't think we'll go that way.

      Thanks, -gjb-

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://372101]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others taking refuge in the Monastery: (5)
As of 2024-04-24 18:31 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found