Class SessionParams
java.lang.Object
com.frostwire.jlibtorrent.SessionParams
This is a parameters pack for configuring the session
before it's started.
-
Constructor Summary
ConstructorsConstructorDescriptionThis constructor can be used to start with the default plugins (ut_metadata, ut_pex and smart_ban).SessionParams(byte[] data) SessionParams(SettingsPack settings) This constructor can be used to start with the default plugins (ut_metadata, ut_pex and smart_ban).SessionParams(File data) This constructor can be used to start with the default plugins (ut_metadata, ut_pex and smart_ban). -
Method Summary
Modifier and TypeMethodDescriptionvoidInternally set the session to use the more appropriate disk I/O back-end.voidInternally set the session to use a simple posix disk I/O back-end, used for systems that don't have a 64-bit virtual address space or don't support memory mapped files.voidsetSettings(SettingsPack settings) The settings to configure the session with.swig()
-
Constructor Details
-
SessionParams
- Parameters:
p- the native object
-
SessionParams
public SessionParams()This constructor can be used to start with the default plugins (ut_metadata, ut_pex and smart_ban). The default values in the settings is to start the default features like upnp, nat-pmp, and dht for example. -
SessionParams
This constructor can be used to start with the default plugins (ut_metadata, ut_pex and smart_ban). The default values in the settings is to start the default features like upnp, nat-pmp, and dht for example. -
SessionParams
public SessionParams(byte[] data) -
SessionParams
This constructor can be used to start with the default plugins (ut_metadata, ut_pex and smart_ban). The default values in the settings is to start the default features like upnp, nat-pmp, and dht for example.- Parameters:
settings- the initial settings pack
-
-
Method Details
-
swig
- Returns:
- the native object
-
getSettings
- Returns:
- the settings pack
-
setSettings
The settings to configure the session with.- Parameters:
settings- the settings pack
-
setPosixDiskIO
public void setPosixDiskIO()Internally set the session to use a simple posix disk I/O back-end, used for systems that don't have a 64-bit virtual address space or don't support memory mapped files. It's implemented using portable C file functions and is single-threaded. This is an advance feature, only to use in particular situations, like Android devices with faulty drivers. -
setDefaultDiskIO
public void setDefaultDiskIO()Internally set the session to use the more appropriate disk I/O back-end. On systems that support memory mapped files (and a 64-bit address space) the memory mapped storage will be constructed, otherwise the portable posix storage.
-