VuFind API Documentation

ConnectorInterface
in

Primo Central connector interface.

Tags
category

VuFind

author

Spencer Lamm slamm1@swarthmore.edu

author

Anna Headley aheadle1@swarthmore.edu

author

Chelsea Lobdell clobdel1@swarthmore.edu

author

Demian Katz demian.katz@villanova.edu

author

Ere Maijala ere.maijala@helsinki.fi

author

Oliver Goldschmidt o.goldschmidt@tuhh.de

license

http://opensource.org/licenses/gpl-2.0.php GNU General Public License

link
https://vufind.org

Table of Contents

getInstitutionCode()  : string
Get the institution code based on user IP. If user is coming from off campus return
getRecord()  : array<string|int, mixed>
Retrieves a document specified by the ID.
query()  : array<string|int, mixed>
Execute a search. Adds all the querystring parameters into $this->client and returns the parsed response

Methods

getInstitutionCode()

Get the institution code based on user IP. If user is coming from off campus return

public getInstitutionCode() : string
Return values
string

getRecord()

Retrieves a document specified by the ID.

public getRecord(string $recordId[, string|null $inst_code = null ][, bool $onCampus = false ]) : array<string|int, mixed>
Parameters
$recordId : string

The document to retrieve from the Primo API

$inst_code : string|null = null

Institution code (optional)

$onCampus : bool = false

Whether the user is on campus

Tags
throws
Exception
Return values
array<string|int, mixed>

An array of query results

query()

Execute a search. Adds all the querystring parameters into $this->client and returns the parsed response

public query(string $institution, array<string|int, mixed> $terms[, array<string|int, mixed> $params = null ]) : array<string|int, mixed>
Parameters
$institution : string

Institution

$terms : array<string|int, mixed>

Associative array: index string: primo index to search (default "any") lookfor string: actual search terms

$params : array<string|int, mixed> = null

Associative array of optional arguments: phrase bool: true if it's a quoted phrase (default false) onCampus bool: (default true) didyoumean bool: (default false) filterList array: (field, value) pairs to filter results (def null) pageNumber string: index of first record (default 1) limit string: number of records to return (default 20) sort string: value to be used by for sorting (default null) highlight bool: whether to highlight search term matches in records highlightStart string: Prefix for a highlighted term highlightEnd string: Suffix for a Highlighted term Anything in $params not listed here will be ignored.

Note: some input parameters accepted by Primo are not implemented here:

  • dym (did you mean)
  • more (get more)
  • lang (specify input language so engine can do lang. recognition)
  • displayField (has to do with highlighting somehow)
Tags
throws
Exception
link
http://www.exlibrisgroup.org/display/PrimoOI/Brief+Search
Return values
array<string|int, mixed>

An array of query results

Search results