The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Webservice::InterMine::Service - an object representation of an Webservice::InterMine Web-Service

SYNOPSIS

  use Webservice::InterMine;

  my $service = Webservice::InterMine->get_service('www.flymine.org/query/service');

  my $query    = $service->new_query;
  my $template = $service->template('Probe_Genes')
      or die "Cannot find template"

  # ... do stuff with your query/template

DESCRIPTION

The service object is the portal to the webservice: it provides the model and templates for the objects you want to construct, and is used by the queries to return results. Generally you won't need to interact with it directly, or if you do, the methods you will be most interested in are those that return objects you can use for running queries.

new( $url, [$user, $pass] )

A service can be constructed directly by passing a webservice url to the new method. To have access to private data (personal templates, saved queries and lists) you also need to provide login information in the form of a username and password.

CONSTRUCTION

Webservice::InterMine->get_service($root, $user, $pass)

Typically as service is most conveniently obtained through the Webservice::InterMine interface.

new($root, $user, $pass)

It can of course be instantiated directly, with a standard call to new.

don't!

You do not have to obtain a service object: simply call the methods on the Webservice::InterMine factory class to obtain new queries, fetch templates and load saved queries.

METHODS

root | user | pass

The values passed into the constructor can be accessed via these methods. Note that the url passed in will have a scheme added if none was provided.

new_query

This returns a new query object for you to define by adding constraints and a view to.

template( $name [$roles] )

This checks to see if there is a template of this name in the webservice, and returns it to you if it exists.

model

returns the model for the webservice. This model is required by many modules for checking validity with the webservice database schema. See InterMine::Model

version

Returns the version of the webservice - used for determining compatibility with different query formats. The version is always an integer. An attempt to get the version is made on instantiation, which serves to validate the webservice.

release

Returns the release string of the webservice

AUTHOR

Alex Kalderimis dev@intermine.org

BUGS

Please report any bugs or feature requests to dev@intermine.org.

SUPPORT

You can find documentation for this module with the perldoc command.

    perldoc Webservice::InterMine

You can also look for information at:

COPYRIGHT AND LICENSE

Copyright 2006 - 2011 FlyMine, all rights reserved.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.