com.facetmap.example.movies
Class MovieResourceSpace
java.lang.Object
com.facetmap.example.movies.MovieResourceSpace
- All Implemented Interfaces:
- ResourceSpace
public class MovieResourceSpace
- extends java.lang.Object
- implements ResourceSpace
Wraps a MovieList in a ResourceSpace implementation, backed by the
classification scheme provided by MovieFacets. This ResourceSpace
will contain Movie objects, and like all ResourceSpace objects, it has an
underlying FacetSpace which describes how its resources are classified. In
this case we take that FacetSpace from MovieFacets.singleton().
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
movies
protected java.util.Map movies
facetSpace
protected FacetSpace facetSpace
MovieResourceSpace
public MovieResourceSpace(MovieList movieList)
getAll
public java.util.Iterator getAll()
throws InternalException
- Description copied from interface:
ResourceSpace
- Returns all resources. Order depends on implementation. This
method can be used to communicate resources between maps or
to output an entire resource space.
- Specified by:
getAll in interface ResourceSpace
- Throws:
InternalException
getById
public Resource getById(int id)
throws InternalException
- Specified by:
getById in interface ResourceSpace
- Throws:
InternalException
getFacetSpace
public FacetSpace getFacetSpace()
- Description copied from interface:
ResourceSpace
- Return the classification scheme by which these Resources are
classified.
- Specified by:
getFacetSpace in interface ResourceSpace
getResourceCount
public int getResourceCount()
throws InternalException
- Specified by:
getResourceCount in interface ResourceSpace
- Throws:
InternalException