Tabnine Logo
Bundle$BundleEntryComponent.getLink
Code IndexAdd Tabnine to your IDE (free)

How to use
getLink
method
in
org.hl7.fhir.dstu3.model.Bundle$BundleEntryComponent

Best Java code snippets using org.hl7.fhir.dstu3.model.Bundle$BundleEntryComponent.getLink (Showing top 9 results out of 315)

origin: ca.uhn.hapi.fhir/hapi-fhir-structures-dstu3

@Override
public Base setProperty(String name, Base value) throws FHIRException {
 if (name.equals("link")) {
  this.getLink().add((BundleLinkComponent) value);
 } else if (name.equals("fullUrl")) {
  this.fullUrl = castToUri(value); // UriType
 } else if (name.equals("resource")) {
  this.resource = castToResource(value); // Resource
 } else if (name.equals("search")) {
  this.search = (BundleEntrySearchComponent) value; // BundleEntrySearchComponent
 } else if (name.equals("request")) {
  this.request = (BundleEntryRequestComponent) value; // BundleEntryRequestComponent
 } else if (name.equals("response")) {
  this.response = (BundleEntryResponseComponent) value; // BundleEntryResponseComponent
 } else
  return super.setProperty(name, value);
 return value;
}
origin: ca.uhn.hapi.fhir/hapi-fhir-structures-dstu3

/**
 * Returns the {@link #getLink() link} which matches a given {@link BundleLinkComponent#getRelation() relation}. 
 * If no link is found which matches the given relation, returns <code>null</code>. If more than one
 * link is found which matches the given relation, returns the first matching BundleLinkComponent.
 * 
 * @param theRelation
 *            The relation, such as "next", or "self. See the constants such as {@link IBaseBundle#LINK_SELF} and {@link IBaseBundle#LINK_NEXT}.
 * @return Returns a matching BundleLinkComponent, or <code>null</code>
 * @see IBaseBundle#LINK_NEXT
 * @see IBaseBundle#LINK_PREV
 * @see IBaseBundle#LINK_SELF
 */
public BundleLinkComponent getLink(String theRelation) {
 org.apache.commons.lang3.Validate.notBlank(theRelation, "theRelation may not be null or empty");
 for (BundleLinkComponent next : getLink()) {
  if (theRelation.equals(next.getRelation())) {
   return next;
  }
 }
 return null;
}
origin: ca.uhn.hapi.fhir/hapi-fhir-structures-dstu3

/**
 * @return The first repetition of repeating field {@link #link}, creating it if it does not already exist
 */
public BundleLinkComponent getLinkFirstRep() { 
 if (getLink().isEmpty()) {
  addLink();
 }
 return getLink().get(0);
}
origin: ca.uhn.hapi.fhir/hapi-fhir-structures-dstu3

/**
 * Returns the {@link #getLink() link} which matches a given {@link BundleLinkComponent#getRelation() relation}. 
 * If no link is found which matches the given relation, creates a new BundleLinkComponent with the
 * given relation and adds it to this Bundle. If more than one
 * link is found which matches the given relation, returns the first matching BundleLinkComponent.
 * 
 * @param theRelation
 *            The relation, such as "next", or "self. See the constants such as {@link IBaseBundle#LINK_SELF} and {@link IBaseBundle#LINK_NEXT}.
 * @return Returns a matching BundleLinkComponent, or <code>null</code>
 * @see IBaseBundle#LINK_NEXT
 * @see IBaseBundle#LINK_PREV
 * @see IBaseBundle#LINK_SELF
 */
public BundleLinkComponent getLinkOrCreate(String theRelation) {
 org.apache.commons.lang3.Validate.notBlank(theRelation, "theRelation may not be null or empty");
 for (BundleLinkComponent next : getLink()) {
  if (theRelation.equals(next.getRelation())) {
   return next;
  }
 }
 BundleLinkComponent retVal = new BundleLinkComponent();
 retVal.setRelation(theRelation);
 getLink().add(retVal);
 return retVal;
}
   protected void listChildren(List<Property> children) {
origin: ca.uhn.hapi.fhir/hapi-fhir-structures-dstu3

@Override
public Base setProperty(int hash, String name, Base value) throws FHIRException {
 switch (hash) {
 case 3321850: // link
  this.getLink().add((BundleLinkComponent) value); // BundleLinkComponent
  return value;
 case -511251360: // fullUrl
  this.fullUrl = castToUri(value); // UriType
  return value;
 case -341064690: // resource
  this.resource = castToResource(value); // Resource
  return value;
 case -906336856: // search
  this.search = (BundleEntrySearchComponent) value; // BundleEntrySearchComponent
  return value;
 case 1095692943: // request
  this.request = (BundleEntryRequestComponent) value; // BundleEntryRequestComponent
  return value;
 case -340323263: // response
  this.response = (BundleEntryResponseComponent) value; // BundleEntryResponseComponent
  return value;
 default: return super.setProperty(hash, name, value);
 }
}
origin: ca.uhn.hapi.fhir/hapi-fhir-converter

public org.hl7.fhir.instance.model.Bundle.BundleEntryComponent convertBundleEntryComponent(org.hl7.fhir.dstu3.model.Bundle.BundleEntryComponent src) throws FHIRException {
 if (src == null || src.isEmpty())
  return null;
 if (advisor.ignoreEntry(src))
  return null;
 org.hl7.fhir.instance.model.Bundle.BundleEntryComponent tgt = new org.hl7.fhir.instance.model.Bundle.BundleEntryComponent();
 copyElement(src, tgt);
 for (org.hl7.fhir.dstu3.model.Bundle.BundleLinkComponent t : src.getLink())
  tgt.addLink(convertBundleLinkComponent(t));
 tgt.setFullUrl(src.getFullUrl());
 org.hl7.fhir.instance.model.Resource res = advisor.convert(src.getResource());
 if (res == null)
  res = convertResource(src.getResource());
 tgt.setResource(res);
 if (src.hasSearch())
  tgt.setSearch(convertBundleEntrySearchComponent(src.getSearch()));
 if (src.hasRequest())
  tgt.setRequest(convertBundleEntryRequestComponent(src.getRequest()));
 if (src.hasResponse())
  tgt.setResponse(convertBundleEntryResponseComponent(src.getResponse()));
 return tgt;
}
origin: ca.uhn.hapi.fhir/hapi-fhir-converter

public static org.hl7.fhir.dstu2016may.model.Bundle.BundleEntryComponent convertBundleEntryComponent(org.hl7.fhir.dstu3.model.Bundle.BundleEntryComponent src) throws FHIRException {
 if (src == null || src.isEmpty())
  return null;
 org.hl7.fhir.dstu2016may.model.Bundle.BundleEntryComponent tgt = new org.hl7.fhir.dstu2016may.model.Bundle.BundleEntryComponent();
 copyElement(src, tgt);
 for (org.hl7.fhir.dstu3.model.Bundle.BundleLinkComponent t : src.getLink())
  tgt.addLink(convertBundleLinkComponent(t));
 if (src.hasFullUrl())
  tgt.setFullUrl(src.getFullUrl());
 tgt.setResource(convertResource(src.getResource()));
 tgt.setSearch(convertBundleEntrySearchComponent(src.getSearch()));
 tgt.setRequest(convertBundleEntryRequestComponent(src.getRequest()));
 tgt.setResponse(convertBundleEntryResponseComponent(src.getResponse()));
 return tgt;
}
origin: jamesagnew/hapi-fhir

public org.hl7.fhir.instance.model.Bundle.BundleEntryComponent convertBundleEntryComponent(org.hl7.fhir.dstu3.model.Bundle.BundleEntryComponent src) throws FHIRException {
 if (src == null || src.isEmpty())
  return null;
 if (advisor.ignoreEntry(src))
  return null;
 org.hl7.fhir.instance.model.Bundle.BundleEntryComponent tgt = new org.hl7.fhir.instance.model.Bundle.BundleEntryComponent();
 copyElement(src, tgt);
 for (org.hl7.fhir.dstu3.model.Bundle.BundleLinkComponent t : src.getLink())
  tgt.addLink(convertBundleLinkComponent(t));
 tgt.setFullUrl(src.getFullUrl());
 org.hl7.fhir.instance.model.Resource res = advisor.convert(src.getResource());
 if (res == null)
  res = convertResource(src.getResource());
 tgt.setResource(res);
 if (src.hasSearch())
  tgt.setSearch(convertBundleEntrySearchComponent(src.getSearch()));
 if (src.hasRequest())
  tgt.setRequest(convertBundleEntryRequestComponent(src.getRequest()));
 if (src.hasResponse())
  tgt.setResponse(convertBundleEntryResponseComponent(src.getResponse()));
 return tgt;
}
origin: jamesagnew/hapi-fhir

public static org.hl7.fhir.dstu2016may.model.Bundle.BundleEntryComponent convertBundleEntryComponent(org.hl7.fhir.dstu3.model.Bundle.BundleEntryComponent src) throws FHIRException {
 if (src == null || src.isEmpty())
  return null;
 org.hl7.fhir.dstu2016may.model.Bundle.BundleEntryComponent tgt = new org.hl7.fhir.dstu2016may.model.Bundle.BundleEntryComponent();
 copyElement(src, tgt);
 for (org.hl7.fhir.dstu3.model.Bundle.BundleLinkComponent t : src.getLink())
  tgt.addLink(convertBundleLinkComponent(t));
 if (src.hasFullUrl())
  tgt.setFullUrl(src.getFullUrl());
 tgt.setResource(convertResource(src.getResource()));
 tgt.setSearch(convertBundleEntrySearchComponent(src.getSearch()));
 tgt.setRequest(convertBundleEntryRequestComponent(src.getRequest()));
 tgt.setResponse(convertBundleEntryResponseComponent(src.getResponse()));
 return tgt;
}
org.hl7.fhir.dstu3.modelBundle$BundleEntryComponentgetLink

Popular methods of Bundle$BundleEntryComponent

  • getResource
  • setResource
  • getRequest
  • <init>
    Constructor
  • getFullUrl
  • getResponse
  • setFullUrl
  • addLink
  • getSearch
  • isEmpty
  • setRequest
  • setResponse
  • setRequest,
  • setResponse,
  • castToResource,
  • castToUri,
  • compareDeep,
  • compareValues,
  • copy,
  • copyValues,
  • getFullUrlElement

Popular in Java

  • Creating JSON documents from java classes using gson
  • scheduleAtFixedRate (ScheduledExecutorService)
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • getApplicationContext (Context)
  • Container (java.awt)
    A generic Abstract Window Toolkit(AWT) container object is a component that can contain other AWT co
  • HashMap (java.util)
    HashMap is an implementation of Map. All optional operations are supported.All elements are permitte
  • Executors (java.util.concurrent)
    Factory and utility methods for Executor, ExecutorService, ScheduledExecutorService, ThreadFactory,
  • Servlet (javax.servlet)
    Defines methods that all servlets must implement. A servlet is a small Java program that runs within
  • JButton (javax.swing)
  • FileUtils (org.apache.commons.io)
    General file manipulation utilities. Facilities are provided in the following areas: * writing to a
  • Top 25 Plugins for Webstorm
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now