public void copyValues(Element dst) { dst.id = id == null ? null : id.copy(); if (extension != null) { dst.extension = new ArrayList<Extension>(); for (Extension i : extension) dst.extension.add(i.copy()); } ; }
private static void initIdType_() { if (null != idType_) return; Properties c = Play.configuration; if (c.containsKey("morphia.id.type")) { debug("reading id type..."); String s = c.getProperty("morphia.id.type"); try { idType_ = IdType.valueOf(s); debug("ID Type set to : %1$s", idType_.name()); if (idType_ == IdType.Long && "1.2beta".equals(VERSION)) { warn( "Caution: Using reference in your model entities might cause problem when you ID type set to Long. Check http://groups.google.com/group/morphia/browse_thread/thread/bdd51121c2845973"); } } catch (Exception e) { String msg = msg_("Error configure morphia id type: %1$s. Id type set to default: ObjectId.", s); fatal(e, msg); throw new ConfigurationException(msg); } } else { idType_ = IdType.ObjectId; } }
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; }
public boolean isEmpty() { return super.isEmpty() && (id == null || id.isEmpty()) && (extension == null || extension.isEmpty()); }
public static IdType newId(String value) { if (value == null) return null; IdType res = new IdType(); res.setValue(value); return res; }