|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.stanwood.media.search.AbstractMediaSearcher
public abstract class AbstractMediaSearcher
This class is used to search for the a media files name
Constructor Summary | |
---|---|
AbstractMediaSearcher(java.util.List<ISearchStrategy> strategies)
Used to create a instance of this class |
Method Summary | |
---|---|
protected abstract SearchResult |
doSearch(java.io.File mediaFile,
java.lang.String term,
java.lang.String year,
java.lang.Integer part,
boolean useSources)
Used todo a search on the term and the year and return the result |
SearchResult |
search(java.io.File mediaFile,
MediaDirectory mediaDir,
boolean useSources)
Used to search for a media id |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public AbstractMediaSearcher(java.util.List<ISearchStrategy> strategies)
strategies
- The search strategies that should be usedMethod Detail |
---|
protected abstract SearchResult doSearch(java.io.File mediaFile, java.lang.String term, java.lang.String year, java.lang.Integer part, boolean useSources) throws java.net.MalformedURLException, java.io.IOException, SourceException, StoreException
term
- The term to search for (Usually a film name or tv show name).year
- The year of the media or null if not to be used in the searchmediaFile
- The media file we are searching foruseSources
- True to search sources, otherwise will only use stores
java.net.MalformedURLException
- Thrown if their is a URL construction problem
java.io.IOException
- Thrown if their is a IO problem
SourceException
- Thrown if their is a problem searching via a source
StoreException
public final SearchResult search(java.io.File mediaFile, MediaDirectory mediaDir, boolean useSources) throws java.net.MalformedURLException, java.io.IOException, SourceException, StoreException
search
in interface IMediaSearcher
mediaFile
- The episode file been processedmediaDir
- The root media directoryuseSources
- True to search sources, otherwise will only use stores
java.net.MalformedURLException
- Thrown if their is a problem construction URL's
java.io.IOException
- Thrown if their is a IO problem
SourceException
- Thrown if their are any source problems
StoreException
- Thrown if their is a problem related to stores
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |