if (artifact.getName() != null) entry.setTitle(artifact.getName()); if (artifact.getCreatedTimestamp() != null) entry.setPublished(artifact.getCreatedTimestamp().toGregorianCalendar().getTime()); if (artifact.getCreatedBy() != null) entry.getAuthors().add(new Person(artifact.getCreatedBy()));
if (artifact.getName() != null) entry.setTitle(artifact.getName()); if (artifact.getCreatedTimestamp() != null) entry.setPublished(artifact.getCreatedTimestamp().toGregorianCalendar().getTime()); if (artifact.getCreatedBy() != null) entry.getAuthors().add(new Person(artifact.getCreatedBy()));
/** * Updates the basic s-ramp meta data. * @param srampArtifact * @throws Exception */ private void updateArtifactMetaData(BaseArtifactType srampArtifact) throws Exception { artificerArtifact.setUuid(srampArtifact.getUuid()); artificerArtifact.setModel(artifactType.getModel()); // may have already been set... if (StringUtils.isBlank(artificerArtifact.getType())) { artificerArtifact.setType(artifactType.getType()); } ArtificerUser createdBy = HibernateEntityFactory.user(srampArtifact.getCreatedBy(), srampArtifact.getCreatedTimestamp()); artificerArtifact.setCreatedBy(createdBy); ArtificerUser modifiedBy = HibernateEntityFactory.user(srampArtifact.getLastModifiedBy(), srampArtifact.getLastModifiedTimestamp()); artificerArtifact.setModifiedBy(modifiedBy); if (srampArtifact.getName() != null) artificerArtifact.setName(srampArtifact.getName()); else artificerArtifact.setName(srampArtifact.getClass().getSimpleName()); artificerArtifact.setDescription(srampArtifact.getDescription()); artificerArtifact.setVersion(srampArtifact.getVersion()); }
if (artifact.getCreatedTimestamp() != null) printProperty(Messages.i18n.format("PrintArtifact.CreatedOn"), artifact.getCreatedTimestamp().toXMLFormat()); printProperty(Messages.i18n.format("PrintArtifact.ModifiedBy"), artifact.getLastModifiedBy()); if (artifact.getLastModifiedTimestamp() != null)