/** * @return URI/URL specifying the location of the referenced series using WADO-RS. */ public String getUrl() { return this.url == null ? null : this.url.getValue(); }
/** * Compares the given string to the string representation of this URI. In many cases it is preferable to use this * instead of the standard {@link #equals(Object)} method, since that method returns <code>false</code> unless it is * passed an instance of {@link UriType} */ public boolean equals(String theString) { return StringUtils.equals(getValueAsString(), theString); }
/** * @return {@link #profile} (A list of profiles [[[StructureDefinition]]]s that this resource claims to conform to. The URL is a reference to [[[StructureDefinition.url]]].) */ // syntactic sugar public UriType addProfileElement() {//2 UriType t = new UriType(); if (this.profile == null) this.profile = new ArrayList<UriType>(); this.profile.add(t); return t; }
public org.hl7.fhir.dstu3.model.ElementDefinition.TypeRefComponent convertElementDefinitionTypeComponent(org.hl7.fhir.instance.model.ElementDefinition.TypeRefComponent src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.dstu3.model.ElementDefinition.TypeRefComponent tgt = new org.hl7.fhir.dstu3.model.ElementDefinition.TypeRefComponent(); copyElement(src, tgt); tgt.setCodeElement(convertCodeToUri(src.getCodeElement())); for (org.hl7.fhir.instance.model.UriType t : src.getProfile()) if (src.hasCode() && "Reference".equals(src.getCode())) tgt.setTargetProfile(t.getValueAsString()); else tgt.setProfile(t.getValue()); for (org.hl7.fhir.instance.model.Enumeration<org.hl7.fhir.instance.model.ElementDefinition.AggregationMode> t : src.getAggregation()) tgt.addAggregation(convertAggregationMode(t.getValue())); return tgt; }
private String pathTail(List<ElementDefinition> diffMatches, int i) { ElementDefinition d = diffMatches.get(i); String s = d.getPath().contains(".") ? d.getPath().substring(d.getPath().lastIndexOf(".")+1) : d.getPath(); return "."+s + (d.hasType() && d.getType().get(0).hasProfile() ? "["+d.getType().get(0).getProfile().get(0).asStringValue()+"]" : ""); }
/** * @param value {@link #link} (Links to the FHIR specification that describes this interaction and the resources involved in more detail.) */ public boolean hasLink(String value) { if (this.link == null) return false; for (UriType v : this.link) if (v.equals(value)) // uri return true; return false; }
/** * @return {@link #policy} (The policy or plan that authorized the activity being recorded. Typically, a single activity may have multiple applicable policies, such as patient consent, guarantor funding, etc. The policy would also indicate the security token used.) */ // syntactic sugar public UriType addPolicyElement() {//2 UriType t = new UriType(); if (this.policy == null) this.policy = new ArrayList<UriType>(); this.policy.add(t); return t; }
public org.hl7.fhir.dstu3.model.ElementDefinition.TypeRefComponent convertElementDefinitionTypeComponent(org.hl7.fhir.instance.model.ElementDefinition.TypeRefComponent src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.dstu3.model.ElementDefinition.TypeRefComponent tgt = new org.hl7.fhir.dstu3.model.ElementDefinition.TypeRefComponent(); copyElement(src, tgt); tgt.setCodeElement(convertCodeToUri(src.getCodeElement())); for (org.hl7.fhir.instance.model.UriType t : src.getProfile()) if (src.hasCode() && "Reference".equals(src.getCode())) tgt.setTargetProfile(t.getValueAsString()); else tgt.setProfile(t.getValue()); for (org.hl7.fhir.instance.model.Enumeration<org.hl7.fhir.instance.model.ElementDefinition.AggregationMode> t : src.getAggregation()) tgt.addAggregation(convertAggregationMode(t.getValue())); return tgt; }
private StructureDefinition getProfileForDataType(TypeRefComponent type) { StructureDefinition sd = null; if (type.hasProfile()) sd = context.fetchResource(StructureDefinition.class, type.getProfile().get(0).asStringValue()); if (sd == null) sd = context.fetchResource(StructureDefinition.class, "http://hl7.org/fhir/StructureDefinition/"+type.getCode()); if (sd == null) System.out.println("XX: failed to find profle for type: " + type.getCode()); // debug GJM return sd; }
public FramesComponent copy() { FramesComponent dst = new FramesComponent(); copyValues(dst); if (frameNumbers != null) { dst.frameNumbers = new ArrayList<UnsignedIntType>(); for (UnsignedIntType i : frameNumbers) dst.frameNumbers.add(i.copy()); }; dst.url = url == null ? null : url.copy(); return dst; }
/** * @param value {@link #compartment} (An absolute URI which is a reference to the definition of a compartment hosted by the system.) */ public boolean hasCompartment(String value) { if (this.compartment == null) return false; for (UriType v : this.compartment) if (v.equals(value)) // uri return true; return false; }
/** * @return Source of the definition for the extension code - a logical name or a URL. */ public String getUrl() { return this.url == null ? null : this.url.getValue(); }
/** * @return {@link #url} (A network address on which the device may be contacted directly.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value */ public UriType getUrlElement() { if (this.url == null) if (Configuration.errorOnAutoCreate()) throw new Error("Attempt to auto-create Device.url"); else if (Configuration.doAutoCreate()) this.url = new UriType(); // bb return this.url; }
private Slicer generateSlicer(ElementDefinition child, ElementDefinitionSlicingComponent slicing, StructureDefinition structure) { // given a child in a structure, it's sliced. figure out the slicing xpath if (child.getPath().endsWith(".extension")) { ElementDefinition ued = getUrlFor(structure, child); if ((ued == null || !ued.hasFixed()) && !(child.getType().get(0).hasProfile())) return new Slicer(false); else { Slicer s = new Slicer(true); String url = (ued == null || !ued.hasFixed()) ? child.getType().get(0).getProfile().get(0).asStringValue() : ((UriType) ued.getFixed()).asStringValue(); s.name = " with URL = '"+url+"'"; s.criteria = "[@url = '"+url+"']"; return s; } } else return new Slicer(false); }
public SourceElementComponent copy() { SourceElementComponent dst = new SourceElementComponent(); copyValues(dst); dst.codeSystem = codeSystem == null ? null : codeSystem.copy(); dst.code = code == null ? null : code.copy(); if (target != null) { dst.target = new ArrayList<TargetElementComponent>(); for (TargetElementComponent i : target) dst.target.add(i.copy()); }; return dst; }
/** * Creates an ID based on a given URL */ public IdType(UriType theUrl) { setValue(theUrl.getValueAsString()); }
/** * @param value {@link #binary} (A binary file that is included in the implementation guide when it is published.) */ public boolean hasBinary(String value) { if (this.binary == null) return false; for (UriType v : this.binary) if (v.equals(value)) // uri return true; return false; }