Package ca.uhn.fhir.model.api

Examples of ca.uhn.fhir.model.api.ExtensionDt


              }
             
            } else if (searchParamChain == null) {
              searchParam.addChain(nextParameter.getName());
              searchParamChain = searchParam.getChain().get(searchParam.getChain().size()-1);
              ExtensionDt ext = new ExtensionDt();
              ext.setUrl(ExtensionConstants.CONF_CHAIN_REQUIRED);
              ext.setValue(new BooleanDt(nextParameter.isRequired()));
              searchParamChain.getUndeclaredExtensions().add(ext);
             
            } else {
              ExtensionDt ext = new ExtensionDt();
              ext.setUrl(ExtensionConstants.CONF_ALSO_CHAIN);
              searchParamChain.getUndeclaredExtensions().add(ext);
             
              ExtensionDt extReq = new ExtensionDt();
              extReq.setUrl(ExtensionConstants.CONF_CHAIN_REQUIRED);
              extReq.setValue(new BooleanDt(nextParameter.isRequired()));
              ext.getUndeclaredExtensions().add(extReq);

            }

          }
View Full Code Here


    /**
     * Default implementation just handles undeclared extensions
     */
    public void enteringNewElementExtension(@SuppressWarnings("unused") StartElement theElement, String theUrlAttr, boolean theIsModifier) {
      if (myPreResourceState != null && getCurrentElement() instanceof ISupportsUndeclaredExtensions) {
        ExtensionDt newExtension = new ExtensionDt(theIsModifier, theUrlAttr);
        ISupportsUndeclaredExtensions elem = (ISupportsUndeclaredExtensions) getCurrentElement();
        if (theIsModifier) {
          elem.getUndeclaredModifierExtensions().add(newExtension);
        } else {
          elem.getUndeclaredExtensions().add(newExtension);
View Full Code Here

  @Override
  public IAccessor getAccessor() {
    return new IAccessor() {
      @Override
      public List<? extends IElement> getValues(Object theTarget) {
        ExtensionDt target = (ExtensionDt) theTarget;
        if (target.getValue() != null) {
          return Collections.singletonList(target.getValue());
        }
        return target.getUndeclaredExtensions();
      }
    };
  }
View Full Code Here

  @Override
  public IMutator getMutator() {
    return new IMutator() {
      @Override
      public void addValue(Object theTarget, IElement theValue) {
        ExtensionDt target = (ExtensionDt) theTarget;
        if (theValue instanceof IDatatype) {
          target.setValue((IDatatype) theTarget);
        } else {
          target.getUndeclaredExtensions().add((ExtensionDt) theValue);
        }
      }
    };
  }
View Full Code Here

     * <b>Definition:</b>
     *
     * </p>
   */
  public ExtensionDt addParameter() {
    ExtensionDt newType = new ExtensionDt();
    getParameter().add(newType);
    return newType;
  }
View Full Code Here

     * <b>Definition:</b>
     *
     * </p>
   */
  public ExtensionDt addParameter() {
    ExtensionDt newType = new ExtensionDt();
    getParameter().add(newType);
    return newType;
  }
View Full Code Here

     * <b>Definition:</b>
     *
     * </p>
   */
  public ExtensionDt addFirst() {
    ExtensionDt newType = new ExtensionDt();
    getFirst().add(newType);
    return newType;
  }
View Full Code Here

     * <b>Definition:</b>
     *
     * </p>
   */
  public ExtensionDt addPrevious() {
    ExtensionDt newType = new ExtensionDt();
    getPrevious().add(newType);
    return newType;
  }
View Full Code Here

     * <b>Definition:</b>
     *
     * </p>
   */
  public ExtensionDt addNext() {
    ExtensionDt newType = new ExtensionDt();
    getNext().add(newType);
    return newType;
  }
View Full Code Here

     * <b>Definition:</b>
     *
     * </p>
   */
  public ExtensionDt addLast() {
    ExtensionDt newType = new ExtensionDt();
    getLast().add(newType);
    return newType;
  }
View Full Code Here

TOP

Related Classes of ca.uhn.fhir.model.api.ExtensionDt

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.