Class LabLink

All Implemented Interfaces:
LimsEntityLink<Lab>, LimsEntityLinkable<Lab>, LimsLink<Lab>, Linkable<Lab>, Locatable, Serializable

public class LabLink extends LimsEntityLinkBase<Lab>
Lab-link is a child element type of labs and provides a URI linking to the detailed representation of a lab.
See Also:
  • Field Details

    • uri

      protected URI uri
      The URI of the lab resource.
    • name

      protected String name
      The name of the lab.
  • Constructor Details

    • LabLink

      public LabLink()
      Constructs a new LabLink instance.
    • LabLink

      public LabLink(URI uri)
      Constructs a new LabLink instance with the specified URI.
      Parameters:
      uri - the URI of the lab resource.
    • LabLink

      public LabLink(URI uri, String name)
      Constructs a new LabLink instance with the specified URI and name.
      Parameters:
      uri - the URI of the lab resource.
      name - the name of the lab.
    • LabLink

      public LabLink(Linkable<Lab> link)
      Constructs a new LabLink instance from a linkable object.
      Parameters:
      link - the linkable object to create the link from.
      Throws:
      NullPointerException - if link is null.
    • LabLink

      public LabLink(Lab lab)
      Constructs a new LabLink instance from a Lab object.
      Parameters:
      lab - the lab to create the link from.
      Throws:
      NullPointerException - if lab is null.
  • Method Details

    • getEntityClass

      public Class<Lab> getEntityClass()
      Gets the entity class for this link.
      Returns:
      the Lab class.
    • getName

      public String getName()
      Gets the name of the lab.
      Returns:
      the name of the lab.
    • setName

      public void setName(String name)
      Sets the name of the lab.
      Parameters:
      name - the name to set.
    • getUri

      public URI getUri()
      Gets the URI of the lab resource.
      Returns:
      the URI of the lab.
    • setUri

      public void setUri(URI uri)
      Sets the URI of the lab resource.
      Parameters:
      uri - the URI to set.
    • getLimsid

      public String getLimsid()
      Gets the LIMS id extracted from the URI.
      Returns:
      the LIMS id.
    • setLimsid

      public void setLimsid(String id)
      Sets the LIMS id. This operation does nothing as the id is derived from the URI.
      Parameters:
      id - the LIMS id (ignored).