Skip to content
Ben Tupper edited this page Jan 19, 2016 · 7 revisions

LimsRefClass

LimsRefClass provides uniform interface for basic GET, PUT, POST, DELETE, etc. transactions as wells as hybrid queries and requests get_containers, get_samples, get_processes, get_artifacts, get_researchers, getByLimsid, etc.

Simple examples are shown on the Home wiki page.

Superclasses

None.

Properties
  • lims LimsRefClass or possibly NULL
  • uri the uri of this node, not all entities have a uri
  • limsid the limsid of this node, not all entities have a limsid
  • ns the XML::xmlNamespace class or possibly NULL
  • node the XML::xmlNode or possibly NULL

Subclasses may add other properties; see each sublcass for details.

Methods

These methods are wrappers around LimsRefClass methods of the same name. Not all subclasses implement these VERBS - some subclasses override these methods when the transaction is not support. Be advised that not ALL subclasses will have this override implemented even if the transaction is disallowed. The descriptions are taken directly from this.

  • GET() Transfer a current representation of the target resource.
  • PUT() Replace all current representations of the target resource with the request payload.
  • POST() Perform resource-specific processing on the request payload.
  • DELETE() Remove all current representations of the target resource.
  • PUSH() a hybrid of the other VERBS to upload a file (possibly deleting an existing file first)

The methods below are for the programmers convenience and may be overwritten by subclasses.

  • show() prints pretty output to the console
  • uri(...) returns the appended value of ... to the baseuri
  • validate_session() testif the connection is valid for transactions
  • check(rsp) check a RESTful response and try to parse the contents
  • create_exception(message) create an XML::xmlNode exception node with the specified message
  • get_byLimsid(limsid, resource) retrieve a list of one or more entities by limsid and resource
  • get_containers(name, type, state, last_modified) get a list of one or more ContainerRefClass nodes, uses batchretrieve()
  • get_samples(name, projectlimsid, projectname) get a list of one or more SampleRefClass nodes, uses batchretrieve
  • get_researcheres(username, form) retrieve a list of ResearcherRefNodes or a data.frame of such.
  • get_processes(last_modified, type, inputartifactlimsid, technamefirst, technamelast, projectname) get a list of one or more ProcessRefClass nodes, uses batchretrieve()
  • get_labs(name, last_modified) get a list of lab entities
  • get_projects(name, last_modified) get a list of project entities
  • get_processtypes(displayname) get a list of process-type entities
  • batchretrieve(uri, rel, rm_dups, asNode) retrieve Nodes using batch_retrieve() (artifacts, files, samples, containers only)
  • batchupdate(list, asNode) update definitions of nodes (artifacts, samples, containers only)
  • batchcreate(list, asNode) create one or more nodes (samples and containers only)
  • get_instruments(name) retrieve a list or data frame of instruments
Related functions
  • Lims(configfile) instantiate a LimsRefClass object
  • batch_retrieve(uri, lims) leverage speedy batch retrieval offered by GLS's API
  • parse_node(node, lims) cast XML::xmlNode to NodeREfClass or a subclass
Clone this wiki locally