Implementing Schema Management

git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/private/luca.frosini/information-system-model@129782 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
Luca Frosini 2016-07-01 15:46:46 +00:00
parent 912bb89691
commit 5559304455
7 changed files with 5 additions and 40 deletions

View File

@ -5,16 +5,9 @@ import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
@Target(ElementType.METHOD)
@Retention(RetentionPolicy.RUNTIME)
public @interface ISPropertyRef {
String name() default "";
String description() default "";
boolean mandatory() default false;
boolean readonly() default false;
boolean nullable() default true;
int min() default -1;
int max() default -1;
String regexpr() default "";
public @interface Method {
}

View File

@ -1,6 +1,6 @@
package org.gcube.informationsystem.model.embedded;
import org.gcube.informationsystem.model.annotations.ISPropertyRef;
/**
@ -8,12 +8,10 @@ import org.gcube.informationsystem.model.annotations.ISPropertyRef;
*/
public interface AccessPolicy extends Embedded {
@ISPropertyRef
public ValueSchema getPolicy();
public void setPolicy(ValueSchema policy);
@ISPropertyRef
public String getNote();
public void setNote(String note);

View File

@ -3,7 +3,6 @@
*/
package org.gcube.informationsystem.model.embedded;
import org.gcube.informationsystem.model.annotations.ISProperty;
/**
@ -12,16 +11,12 @@ import org.gcube.informationsystem.model.annotations.ISProperty;
*/
public interface Header extends Embedded {
@ISProperty
public String getID();
@ISProperty
public String getCreator();
@ISProperty
public Long getCreationTime();
@ISProperty
public Long getLastUpdateTime();

View File

@ -1,16 +1,7 @@
/**
*
*/
package org.gcube.informationsystem.model.embedded;
import org.gcube.informationsystem.model.annotations.ISProperty;
import org.gcube.informationsystem.model.annotations.ISPropertyRef;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
*
*/
public interface RelationProperty extends Embedded {
@ -42,12 +33,10 @@ public interface RelationProperty extends Embedded {
}
@ISProperty
public ReferentiaIntegrity getReferentialIntegrity();
public void setReferentialIntegrity(ReferentiaIntegrity referentialIntegrity);
@ISPropertyRef
public AccessPolicy getPolicy();
public void setPolicy(AccessPolicy accessPolicy);

View File

@ -5,8 +5,6 @@ package org.gcube.informationsystem.model.embedded;
import java.net.URI;
import org.gcube.informationsystem.model.annotations.ISPropertyRef;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* Base Interface for all type described by a value and a schema retrieved
@ -14,12 +12,10 @@ import org.gcube.informationsystem.model.annotations.ISPropertyRef;
*/
public interface ValueSchema extends Embedded {
@ISPropertyRef
public String getValue();
public void setValue(String value);
@ISPropertyRef
public URI getSchema();
public void setSchema(URI schema);

View File

@ -4,7 +4,6 @@
package org.gcube.informationsystem.model.entity;
import org.gcube.informationsystem.model.annotations.Abstract;
import org.gcube.informationsystem.model.annotations.ISPropertyRef;
import org.gcube.informationsystem.model.embedded.Header;
@ -14,7 +13,6 @@ import org.gcube.informationsystem.model.embedded.Header;
@Abstract
public interface Entity {
@ISPropertyRef
public Header getHeader();
}

View File

@ -3,12 +3,9 @@
*/
package org.gcube.informationsystem.model.relation;
import org.gcube.informationsystem.model.annotations.ISPropertyRef;
import org.gcube.informationsystem.model.embedded.RelationProperty;
import org.gcube.informationsystem.model.entity.Entity;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
*/
@ -18,7 +15,6 @@ public interface Relation<Out extends Entity, In extends Entity> {
public In getTarget();
@ISPropertyRef
public RelationProperty getRelationProperty();
}