|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.anidb.udp.UdpFileFactory
public class UdpFileFactory
A factory for File
objects.
Method Summary | |
---|---|
File |
getFile(long fileId,
FileMask fileMask,
AnimeFileMask animeFileMask)
Returns the file with the given Id. |
java.util.List<File> |
getFiles(long animeId,
long groupId,
long episodeNumber,
FileMask fileMask,
AnimeFileMask animeFileMask)
Returns the files with the given anime Id, group Id and episode number. |
java.util.List<File> |
getFiles(long size,
java.lang.String ed2kHash,
FileMask fileMask,
AnimeFileMask animeFileMask)
Returns the files with the given size and ed2k hash. |
java.util.List<File> |
getFiles(long animeId,
java.lang.String groupName,
long episodeNumber,
FileMask fileMask,
AnimeFileMask animeFileMask)
Returns the files with the given anime Id, group name and episode number. |
java.util.List<File> |
getFiles(java.lang.String animeName,
long groupId,
long episodeNumber,
FileMask fileMask,
AnimeFileMask animeFileMask)
Returns the files with the given anime name, group Id and episode number. |
java.util.List<File> |
getFiles(java.lang.String animeName,
java.lang.String groupName,
long episodeNumber,
FileMask fileMask,
AnimeFileMask animeFileMask)
Returns the files with the given anime name, group name and episode number. |
static UdpFileFactory |
getInstance(UdpConnection conn)
Returns an instance of this class. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static UdpFileFactory getInstance(UdpConnection conn)
conn
- The connection.
java.lang.IllegalArgumentException
- If the connection is null
.public File getFile(long fileId, FileMask fileMask, AnimeFileMask animeFileMask) throws UdpConnectionException, AniDbException
Returns the file with the given Id.
Only the fields specified by the two masks will be filled.
fileId
- The file Id.fileMask
- The file mask.animeFileMask
- The anime file mask.
java.lang.IllegalArgumentException
- If the file mask is null
.
java.lang.IllegalArgumentException
- If the anime file mask is
null
.
UdpConnectionException
- If a connection problem occured.
AniDbException
- If a problem with AniDB occured.UdpReturnCodes.NO_SUCH_FILE
public java.util.List<File> getFiles(long size, java.lang.String ed2kHash, FileMask fileMask, AnimeFileMask animeFileMask) throws UdpConnectionException, AniDbException
Returns the files with the given size and ed2k hash.
Only the fields specified by the two masks will be filled.
size
- The size.ed2kHash
- The ed2k hash.fileMask
- The file mask.animeFileMask
- The anime file mask.
java.lang.IllegalArgumentException
- If the size is less than 1
.
java.lang.IllegalArgumentException
- If the ed2k hash is null
.
java.lang.IllegalArgumentException
- If the file mask is null
.
java.lang.IllegalArgumentException
- If the anime file mask is
null
.
UdpConnectionException
- If a connection problem occured.
AniDbException
- If a problem with AniDB occured.UdpReturnCodes.NO_SUCH_FILE
public java.util.List<File> getFiles(java.lang.String animeName, java.lang.String groupName, long episodeNumber, FileMask fileMask, AnimeFileMask animeFileMask) throws UdpConnectionException, AniDbException
Returns the files with the given anime name, group name and episode number.
Only the fields specified by the two masks will be filled.
animeName
- The anime name.groupName
- The group name.episodeNumber
- The episode number.fileMask
- The file mask.animeFileMask
- The anime file mask.
java.lang.IllegalArgumentException
- If the anime name is null
.
java.lang.IllegalArgumentException
- If the group name is null
.
java.lang.IllegalArgumentException
- If the file mask is null
.
java.lang.IllegalArgumentException
- If the anime file mask is
null
.
UdpConnectionException
- If a connection problem occured.
AniDbException
- If a problem with AniDB occured.UdpReturnCodes.NO_SUCH_FILE
public java.util.List<File> getFiles(java.lang.String animeName, long groupId, long episodeNumber, FileMask fileMask, AnimeFileMask animeFileMask) throws UdpConnectionException, AniDbException
Returns the files with the given anime name, group Id and episode number.
Only the fields specified by the two masks will be filled.
animeName
- The anime name.groupId
- The group Id.episodeNumber
- The episode number.fileMask
- The file mask.animeFileMask
- The anime file mask.
java.lang.IllegalArgumentException
- If the anime name is null
.
java.lang.IllegalArgumentException
- If the file mask is null
.
java.lang.IllegalArgumentException
- If the anime file mask is
null
.
UdpConnectionException
- If a connection problem occured.
AniDbException
- If a problem with AniDB occured.UdpReturnCodes.NO_SUCH_FILE
public java.util.List<File> getFiles(long animeId, java.lang.String groupName, long episodeNumber, FileMask fileMask, AnimeFileMask animeFileMask) throws UdpConnectionException, AniDbException
Returns the files with the given anime Id, group name and episode number.
Only the fields specified by the two masks will be filled.
animeId
- The anime Id.groupName
- The group name.episodeNumber
- The episode number.fileMask
- The file mask.animeFileMask
- The anime file mask.
java.lang.IllegalArgumentException
- If the group name is null
.
java.lang.IllegalArgumentException
- If the file mask is null
.
java.lang.IllegalArgumentException
- If the anime file mask is
null
.
UdpConnectionException
- If a connection problem occured.
AniDbException
- If a problem with AniDB occured.UdpReturnCodes.NO_SUCH_FILE
public java.util.List<File> getFiles(long animeId, long groupId, long episodeNumber, FileMask fileMask, AnimeFileMask animeFileMask) throws UdpConnectionException, AniDbException
Returns the files with the given anime Id, group Id and episode number.
Only the fields specified by the two masks will be filled.
animeId
- The anime Id.groupId
- The group Id.episodeNumber
- The episode number.fileMask
- The file mask.animeFileMask
- The anime file mask.
java.lang.IllegalArgumentException
- If the file mask is null
.
java.lang.IllegalArgumentException
- If the anime file mask is
null
.
UdpConnectionException
- If a connection problem occured.
AniDbException
- If a problem with AniDB occured.UdpReturnCodes.NO_SUCH_FILE
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |