Commit ebf60222 authored by Matija Obreza's avatar Matija Obreza
Browse files

Upgraded to application-blocks@1.1-SNAPSHOT

parent c740b965
......@@ -28,6 +28,7 @@ import javax.persistence.ManyToMany;
import javax.persistence.OrderColumn;
import org.genesys.blocks.model.AuditedVersionedModel;
import org.genesys.blocks.model.Copyable;
/**
* {@link ImageGallery} is a collection of ordered {@link RepositoryImage} instances.
......@@ -38,7 +39,7 @@ import org.genesys.blocks.model.AuditedVersionedModel;
* @author mobreza
*/
@Entity(name = "repositorygallery")
public class ImageGallery extends AuditedVersionedModel<ImageGallery> {
public class ImageGallery extends AuditedVersionedModel implements Copyable<ImageGallery> {
private static final long serialVersionUID = 6043583851401365284L;
......@@ -140,9 +141,9 @@ public class ImageGallery extends AuditedVersionedModel<ImageGallery> {
@Override
public ImageGallery apply(ImageGallery source) {
super.apply((AuditedVersionedModel<ImageGallery>) source);
this.description = source.description;
// TODO does this make sense?
this.images = new ArrayList<>(source.images);
this.path = source.path;
this.title = source.title;
......
......@@ -26,8 +26,8 @@ import org.genesys.filerepository.metadata.ImageMetadata;
// TODO: Auto-generated Javadoc
/**
* An {@link RepositoryDocument} is an graphics file in one of the supported image formats (PNG and JPG). It extends the {@link RepositoryFile} by including image-specific metadata
* defined in {@link ImageMetadata}.
* An {@link RepositoryDocument} is an graphics file in one of the supported image formats (PNG and JPG). It extends the
* {@link RepositoryFile} by including image-specific metadata defined in {@link ImageMetadata}.
*
* @author mobreza
*/
......@@ -96,4 +96,12 @@ public class RepositoryDocument extends RepositoryFile implements DocumentMetada
this.abstrct = abstrct;
}
public RepositoryDocument apply(RepositoryDocument source) {
super.apply(source);
this.abstrct = source.abstrct;
this.language = source.language;
return this;
}
}
......@@ -31,6 +31,7 @@ import javax.persistence.TemporalType;
import javax.persistence.Transient;
import org.genesys.blocks.model.AuditedVersionedModel;
import org.genesys.blocks.model.Copyable;
import org.genesys.filerepository.metadata.BaseMetadata;
// TODO: Auto-generated Javadoc
......@@ -40,7 +41,7 @@ import org.genesys.filerepository.metadata.BaseMetadata;
@Entity
@Table(name = "repositoryfile", indexes = { @Index(unique = false, columnList = "path", name = "IX_repoFile_path") })
@Inheritance(strategy = InheritanceType.TABLE_PER_CLASS)
public class RepositoryFile extends AuditedVersionedModel<RepositoryFile> implements BaseMetadata {
public class RepositoryFile extends AuditedVersionedModel implements BaseMetadata, Copyable<RepositoryFile> {
/** The Constant serialVersionUID. */
private static final long serialVersionUID = -4816923593950502695L;
......@@ -569,7 +570,6 @@ public class RepositoryFile extends AuditedVersionedModel<RepositoryFile> implem
@Override
public RepositoryFile apply(RepositoryFile source) {
super.apply((AuditedVersionedModel<RepositoryFile>) source);
this.accessRights = source.accessRights;
this.bibliographicCitation = source.bibliographicCitation;
......
......@@ -78,11 +78,11 @@
<jdk.source>1.8</jdk.source>
<show.deprecations>false</show.deprecations>
<application.blocks.version>1.0-SNAPSHOT</application.blocks.version>
<application.blocks.version>1.1-SNAPSHOT</application.blocks.version>
<junit.version>4.12</junit.version>
<org.hamcrest.version>1.3</org.hamcrest.version>
<commons.io.version>2.4</commons.io.version>
<spring.version>4.3.2.RELEASE</spring.version>
<spring.data.version>1.10.4.RELEASE</spring.data.version>
<querydsl.version>4.1.4</querydsl.version>
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment