@Generated(value = "com.sun.tools.xjc.Driver", date = "2018-04-24T11:17:38-05:00", comments = "JAXB RI v2.2.11") public StringBuilder appendFields(ObjectLocator locator, StringBuilder buffer, ToStringStrategy strategy) { { XMLGregorianCalendar theValue; theValue = this.getValue(); strategy.appendField(locator, this, "value", buffer, theValue); } return buffer; }
public static void calculateLastModified(ActivitiesContainer actContainerV2) { if(actContainerV2 != null) { Collection<? extends Activity> activities = actContainerV2.retrieveActivities(); if (activities != null && !activities.isEmpty()) { Iterator<? extends Activity> activitiesIterator = activities.iterator(); XMLGregorianCalendar latest = activitiesIterator.next().getLastModifiedDate().getValue(); while (activitiesIterator.hasNext()) { Activity activity = activitiesIterator.next(); if (latest.compare(activity.getLastModifiedDate().getValue()) == -1) { latest = activity.getLastModifiedDate().getValue(); } } actContainerV2.setLastModifiedDate(new LastModifiedDate(latest)); } } }
@Override public PersonalDetails getPersonalDetails(String orcid) { Date lastModified = getLastModifiedDate(orcid); long lastModifiedTime = lastModified.getTime(); PersonalDetails personalDetails = new PersonalDetails(); Name name = recordNameManager.getRecordName(orcid); if (name != null) { personalDetails.setName(name); } Biography bio = biographyManager.getBiography(orcid); if (bio != null) { personalDetails.setBiography(bio); } OtherNames otherNames = otherNameManager.getOtherNames(orcid); OtherNames filteredOtherNames = new OtherNames(); personalDetails.setOtherNames(filteredOtherNames); if (otherNames != null && otherNames.getOtherNames() != null && !otherNames.getOtherNames().isEmpty()) { // Lets copy the list so we don't modify the cached collection List<OtherName> filteredList = new ArrayList<OtherName>(otherNames.getOtherNames()); filteredOtherNames.setOtherNames(filteredList); } if (personalDetails.getLastModifiedDate() == null || personalDetails.getLastModifiedDate().getValue() == null) { personalDetails.setLastModifiedDate(new LastModifiedDate(DateUtils.convertToXMLGregorianCalendar(lastModified))); } return personalDetails; }
if (personalDetails.getLastModifiedDate() == null || personalDetails.getLastModifiedDate().getValue() == null) { personalDetails.setLastModifiedDate(new LastModifiedDate(DateUtils.convertToXMLGregorianCalendar(lastModified)));
Literal when = calendarAsLiteral(history.getLastModifiedDate().getValue(), m); profileDoc.addLiteral(PAV.lastUpdateOn, when); profileDoc.addLiteral(PROV.generatedAtTime, when);