GNDMS 0.6.0
RESTful verison of GNDMS
|
The slice kind provider which handles the available subspaces providing a mapping of slice kind ids and slice kinds. More...
Public Member Functions | |
SliceKindProviderImpl (final EntityManagerFactory emf) | |
boolean | exists (String subspace, String sliceKind) |
Checks whether a given slice kind id exists for the subspace. | |
List< String > | list (String subspace) throws NoSuchElementException |
Returns a list containing all existing slice kind ids for a subspace. | |
SliceKind | get (String subspace, String sliceKind) throws NoSuchElementException |
Returns the slice kind for a given slice kind id in a subspace. | |
void | create (final String sliceKindId, final String config) |
Protected Member Functions | |
String | getListQuery () |
The slice kind provider which handles the available subspaces providing a mapping of slice kind ids and slice kinds.
boolean de.zib.gndms.logic.model.dspace.SliceKindProviderImpl.exists | ( | String | subspace, |
String | sliceKind | ||
) |
Checks whether a given slice kind id exists for the subspace.
subspace | The considered subspace. |
sliceKind | The slice kind id. |
Implements de.zib.gndms.logic.model.dspace.SliceKindProvider.
{
return super.exists( sliceKind );
}
SliceKind de.zib.gndms.logic.model.dspace.SliceKindProviderImpl.get | ( | String | subspace, |
String | sliceKind | ||
) | throws NoSuchElementException |
Returns the slice kind for a given slice kind id in a subspace.
subspace | The considered subspace. |
sliceKind | The requested slice kind id. |
NoSuchElementException | if the subspace does not exist. |
Implements de.zib.gndms.logic.model.dspace.SliceKindProvider.
{
return super.get( sliceKind );
}
List< String > de.zib.gndms.logic.model.dspace.SliceKindProviderImpl.list | ( | String | subspace | ) | throws NoSuchElementException |
Returns a list containing all existing slice kind ids for a subspace.
subspace | The considered subspace. |
NoSuchElementException | if the subspace does not exist. |
Implements de.zib.gndms.logic.model.dspace.SliceKindProvider.
{ EntityManager em = emf.createEntityManager(); Query query = em.createNamedQuery( getListQuery() ); query.setParameter( "idParam", subspace ); return query.getResultList(); }