com.epnet.eit2.rest.client
Class EIT2Client

java.lang.Object
  extended bycom.epnet.eit2.rest.client.AbstractEIT2Client
      extended bycom.epnet.eit2.rest.client.EIT2Client
Direct Known Subclasses:
UserEIT2Client

public class EIT2Client
extends AbstractEIT2Client

A funtional EIT2 REST client. Provides parametrized methods and internally builds the querystring. There are two versions, a mandatory-parameters version and an all-parameters one.

Author:
msanchez@ebscohost.com

Field Summary
 
Fields inherited from class com.epnet.eit2.rest.client.AbstractEIT2Client
baseURI, browseServicePath, infoServicePath, searchServicePath
 
Constructor Summary
EIT2Client(java.lang.String host)
          Creates an instance of the client
 
Method Summary
 java.io.InputStream browse(java.lang.String prof, java.lang.String pwd, java.lang.String term, java.lang.String db, java.lang.String index)
          The Browse method is used to view indexes such as Authors or Subject Terms on an EBSCOhost database.
 java.io.InputStream browse(java.lang.String prof, java.lang.String pwd, java.lang.String term, java.lang.String numrec_20, java.lang.String db, java.lang.String index)
          The Browse method is used to view indexes such as Authors or Subject Terms on an EBSCOhost database.
 java.io.InputStream info(java.lang.String prof, java.lang.String pwd)
          The Info method allows the Data Partner to receive a list of databases available to the given profile as well as the attributes of those databases such as the sort fields and indexes allowed by each database.
 java.io.InputStream search(java.lang.String prof, java.lang.String pwd, java.lang.String query, java.lang.String db)
          The Search method is used to perform basic searches on EBSCOhost reference system.
 java.io.InputStream search(java.lang.String prof, java.lang.String pwd, java.lang.String query, java.lang.String startrec_1, java.lang.String numrec_10, java.lang.String sort_date, java.lang.String db, java.lang.String format_brief, java.lang.String subset_)
          The Search method is used to perform basic searches on EBSCOhost reference system.
 
Methods inherited from class com.epnet.eit2.rest.client.AbstractEIT2Client
browse, info, search, service
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EIT2Client

public EIT2Client(java.lang.String host)
           throws EITClientException
Creates an instance of the client

Parameters:
host - The EIT2 REST host
Throws:
EITClientException - If any network errors occur with the request
Method Detail

info

public java.io.InputStream info(java.lang.String prof,
                                java.lang.String pwd)
                         throws EITClientException
The Info method allows the Data Partner to receive a list of databases available to the given profile as well as the attributes of those databases such as the sort fields and indexes allowed by each database.

Parameters:
prof - eit profile
pwd - profile password
Returns:
InputStream to read from
Throws:
EITClientException - If any network errors occur with the request

browse

public java.io.InputStream browse(java.lang.String prof,
                                  java.lang.String pwd,
                                  java.lang.String term,
                                  java.lang.String numrec_20,
                                  java.lang.String db,
                                  java.lang.String index)
                           throws EITClientException
The Browse method is used to view indexes such as Authors or Subject Terms on an EBSCOhost database. Note that the index availability can be different per database. Non-mandatory parameters are marked by "_"; set to null to use default value.

Parameters:
prof - eit profile
pwd - profile password
term - Search terms.
numrec_20 - Number of records to return for this search
db - DB to browse at a time
index - The DB index to browse
Returns:
InputStream to read from
Throws:
EITClientException - If any network errors occur with the request

browse

public java.io.InputStream browse(java.lang.String prof,
                                  java.lang.String pwd,
                                  java.lang.String term,
                                  java.lang.String db,
                                  java.lang.String index)
                           throws EITClientException
The Browse method is used to view indexes such as Authors or Subject Terms on an EBSCOhost database. Note that the index availability can be different per database.

Parameters:
prof - eit profile
pwd - profile password
term - Search terms.
db - DB to browse
index - DB index to browse
Returns:
InputStream to read from
Throws:
EITClientException - If any network errors occur with the request

search

public java.io.InputStream search(java.lang.String prof,
                                  java.lang.String pwd,
                                  java.lang.String query,
                                  java.lang.String startrec_1,
                                  java.lang.String numrec_10,
                                  java.lang.String sort_date,
                                  java.lang.String db,
                                  java.lang.String format_brief,
                                  java.lang.String subset_)
                           throws EITClientException
The Search method is used to perform basic searches on EBSCOhost reference system. Abstracts as well as the full text for documents and articles can be retrieved using this method. When available, full text articles can also be downloaded in pdf format. Non-mandatory parameters are marked by "_"; set to null to use default value.

Parameters:
prof - eit profile
pwd - profile password
query - Search terms. Can be a bquery.
startrec_1 - Start record. Use for pagination.
numrec_10 - Number of records to return at a time. Use for pagination.
sort_date - Sort type. Varies per database. Use infor to introspect DB.
db - DB to search
format_brief - Format type: brief, detailed, full.
subset_ - Use info method for DB subsets
Returns:
InputStream to read from
Throws:
EITClientException - If any network errors occur with the request

search

public java.io.InputStream search(java.lang.String prof,
                                  java.lang.String pwd,
                                  java.lang.String query,
                                  java.lang.String db)
                           throws EITClientException
The Search method is used to perform basic searches on EBSCOhost reference system. Abstracts as well as the full text for documents and articles can be retrieved using this method. When available, full text articles can also be downloaded in pdf format.

Parameters:
prof - eit profile
pwd - profile password
query - Search terms. Can be a bquery.
db - DB to search
Returns:
InputStream to read from
Throws:
EITClientException - If any network errors occur with the request