|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.elite.jdcbot.framework.DUEntity
public class DUEntity
Created on 26-May-08
Download/Upload Entity.
Field Summary | |
---|---|
java.lang.String |
file
The name or TTH of the file to download. |
static int |
FILE_TYPE
|
static int |
FILELIST_TYPE
|
int |
fileType
|
java.io.InputStream |
in
The InputStream from which the file to be uploaded is to be read. |
long |
len
The total number of bytes starting from start of the file to download. |
static int |
NO_AUTO_FILELIST_DECOMPRESS_SETTING
|
static int |
NO_SETTING
This setting is set to zero, i.e. |
java.io.OutputStream |
os
The OutputStream to which the downloaded file is to be written. |
int |
settingFlags
It is used to set some flags like, if you donot want the downloaded file list to be automatically decompressed by the framework then set it to NO_AUTO_FILELIST_DECOMPRESS_SETTING. |
long |
start
The starting byte offset of the file from which to start download. |
static int |
TTHL_TYPE
|
Constructor Summary | |
---|---|
DUEntity()
|
|
DUEntity(DUEntity due)
|
|
DUEntity(int fileType,
java.io.InputStream IN)
|
|
DUEntity(int fileType,
java.io.OutputStream OS,
int settings)
|
|
DUEntity(int fileType,
java.lang.String file2Download,
int Start,
int Len,
java.io.InputStream IN,
int settings)
|
|
DUEntity(int fileType,
java.lang.String file2Download,
int Start,
int Len,
java.io.OutputStream OS,
int settings)
|
Method Summary | |
---|---|
DUEntity |
getDummyCopy()
|
java.lang.String |
getFileType()
|
boolean |
isSettingSet(int flag)
|
static int |
prepareSettings(int... flags)
Its only job is to accept lots of setting flags as arguments and create a single integer that represents all those settings. |
void |
setSetting(int flag)
|
void |
unsetSetting(int flag)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int FILE_TYPE
public static final int FILELIST_TYPE
public static final int TTHL_TYPE
public static final int NO_SETTING
public static final int NO_AUTO_FILELIST_DECOMPRESS_SETTING
public java.lang.String file
public java.io.OutputStream os
public java.io.InputStream in
public long start
public long len
public int fileType
public int settingFlags
setSetting
to set the setting and unsetSetting
to unset
an already set setting.
Constructor Detail |
---|
public DUEntity()
public DUEntity(int fileType, java.lang.String file2Download, int Start, int Len, java.io.OutputStream OS, int settings)
public DUEntity(int fileType, java.io.OutputStream OS, int settings)
public DUEntity(int fileType, java.lang.String file2Download, int Start, int Len, java.io.InputStream IN, int settings)
public DUEntity(int fileType, java.io.InputStream IN)
public DUEntity(DUEntity due)
Method Detail |
---|
public DUEntity getDummyCopy()
public java.lang.String getFileType()
public void setSetting(int flag)
public void unsetSetting(int flag)
public boolean isSettingSet(int flag)
public static int prepareSettings(int... flags)
settingFlags
at all,
it will simply return the combined setting flags. You can pass the output of this method to isSettingSet
to check for multiple settings at one call, or pass this value to constructors.
flags
- The settings as arguments.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |