001package org.hl7.fhir.r5.profilemodel;
002
003import java.util.List;
004
005import org.hl7.fhir.r5.model.StructureDefinition;
006
007public class PEDefinitionResource extends PEDefinition {
008
009  public PEDefinitionResource(PEBuilder builder, StructureDefinition profile, String ppath) {
010    super(builder, profile.getName(), profile, profile.getSnapshot().getElementFirstRep(), ppath);
011  }
012
013  @Override
014  public void listTypes(List<PEType> types) {
015    types.add(new PEType(profile.getName(), profile.getType(), profile.getUrl()));
016  }
017
018  @Override
019  protected void makeChildren(String typeUrl, List<PEDefinition> children, boolean allFixed) {
020    children.addAll(builder.listChildren(allFixed, this, profile, definition, null));
021  }
022
023  @Override
024  public String fhirpath() {
025    return profile.getType();
026  }
027
028  
029}