use of org.molgenis.data.meta.model.EntityType in project molgenis by molgenis.
the class RepositorySecurityDecorator method count.
@Override
public long count() {
EntityType entityType = delegate().getEntityType();
validatePermission(entityType, EntityTypePermission.COUNT);
return delegate().count();
}
use of org.molgenis.data.meta.model.EntityType in project molgenis by molgenis.
the class RepositorySecurityDecorator method deleteAll.
@Override
public void deleteAll() {
EntityType entityType = delegate().getEntityType();
validatePermission(entityType, EntityTypePermission.WRITE);
delegate().deleteAll();
}
use of org.molgenis.data.meta.model.EntityType in project molgenis by molgenis.
the class RepositorySecurityDecorator method iterator.
@Override
public Iterator<Entity> iterator() {
EntityType entityType = delegate().getEntityType();
validatePermission(entityType, EntityTypePermission.READ);
return delegate().iterator();
}
use of org.molgenis.data.meta.model.EntityType in project molgenis by molgenis.
the class RepositorySecurityDecorator method delete.
@Override
public void delete(Entity entity) {
EntityType entityType = delegate().getEntityType();
validatePermission(entityType, EntityTypePermission.WRITE);
delegate().delete(entity);
}
use of org.molgenis.data.meta.model.EntityType in project molgenis by molgenis.
the class RepositorySecurityDecorator method add.
@Override
public Integer add(Stream<Entity> entities) {
EntityType entityType = delegate().getEntityType();
validatePermission(entityType, EntityTypePermission.WRITE);
return delegate().add(entities);
}
Aggregations