Esempio n. 1
0
 protected Meta toMeta(Collection<TagDefinition> tagDefinitions) {
   Meta retVal = new Meta();
   for (TagDefinition next : tagDefinitions) {
     switch (next.getTagType()) {
       case PROFILE:
         retVal.addProfile(next.getCode());
         break;
       case SECURITY_LABEL:
         retVal
             .addSecurity()
             .setSystem(next.getSystem())
             .setCode(next.getCode())
             .setDisplay(next.getDisplay());
         break;
       case TAG:
         retVal
             .addTag()
             .setSystem(next.getSystem())
             .setCode(next.getCode())
             .setDisplay(next.getDisplay());
         break;
     }
   }
   return retVal;
 }
Esempio n. 2
0
 public Meta copy() {
   Meta dst = new Meta();
   copyValues(dst);
   dst.versionId = versionId == null ? null : versionId.copy();
   dst.lastUpdated = lastUpdated == null ? null : lastUpdated.copy();
   if (profile != null) {
     dst.profile = new ArrayList<UriType>();
     for (UriType i : profile) dst.profile.add(i.copy());
   }
   ;
   if (security != null) {
     dst.security = new ArrayList<Coding>();
     for (Coding i : security) dst.security.add(i.copy());
   }
   ;
   if (tag != null) {
     dst.tag = new ArrayList<Coding>();
     for (Coding i : tag) dst.tag.add(i.copy());
   }
   ;
   return dst;
 }