|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.gudy.azureus2.platform.win32.PlatformManagerImpl
public class PlatformManagerImpl
Field Summary | |
---|---|
static String |
DLL_NAME
|
static String |
NEW_MAIN_ASSOC
|
static String |
OLD_MAIN_ASS0C
|
static int |
RT_AZ
|
static int |
RT_NONE
|
static int |
RT_OTHER
|
static String |
VUZE_ASSOC
|
Fields inherited from interface org.gudy.azureus2.platform.PlatformManager |
---|
PT_MACOSX, PT_OTHER, PT_UNIX, PT_WINDOWS, SD_ALL, SD_HIBERNATE, SD_SHUTDOWN, SD_SLEEP, USER_REQUEST_INFO, USER_REQUEST_QUESTION, USER_REQUEST_WARNING |
Fields inherited from interface org.gudy.azureus2.plugins.platform.PlatformManager |
---|
LOC_DOCUMENTS, LOC_MUSIC, LOC_USER_DATA, LOC_VIDEO |
Fields inherited from interface org.gudy.azureus2.platform.win32.access.AEWin32AccessListener |
---|
ET_RESUME, ET_SHUTDOWN, ET_SUSPEND, RT_SUSPEND_DENY |
Constructor Summary | |
---|---|
protected |
PlatformManagerImpl()
|
Method Summary | |
---|---|
void |
addListener(PlatformManagerListener listener)
|
protected void |
applyPatches()
|
protected void |
checkExeKey(File exe)
|
protected void |
checkExeKey(int hkey,
File exe)
|
void |
copyFilePermissions(String from_file_name,
String to_file_name)
|
protected boolean |
createKey(int type,
String key)
|
void |
createProcess(String command_line,
boolean inherit_handles)
|
void |
dispose()
Does nothing |
int |
eventOccurred(int type)
|
protected void |
fixPermissions(File parent,
File dir)
|
void |
generate(IndentWriter writer)
|
int |
getAdditionalFileTypeRegistrationDetails(String name,
String type)
|
String |
getApplicationCommandLine()
|
protected File |
getApplicationEXELocation()
|
String |
getComputerName()
|
String[] |
getExplicitVMOptions()
|
protected int |
getIconIndex()
|
File |
getLocation(long location_id)
Get a well-known location, if defined for the platform |
int |
getMaxOpenFiles()
This max-open-files concept here is from linux/osx where network connections are treated as 'files' |
int |
getPlatformType()
|
boolean |
getPreventComputerSleep()
|
boolean |
getRunAtLogin()
|
int |
getShutdownTypes()
|
static PlatformManagerImpl |
getSingleton()
|
String |
getUserDataDirectory()
|
String |
getVersion()
|
File |
getVMOptionFile()
|
boolean |
hasCapability(PlatformManagerCapabilities capability)
Gets whether the platform manager supports a capability |
boolean |
isAdditionalFileTypeRegistered(String name,
String type)
Checks to see if the supplied file type is registered with this application |
boolean |
isApplicationRegistered()
|
Class<?> |
loadClass(ClassLoader loader,
String class_name)
Gives a particular platform the ability to alter the class-loading method |
void |
performRecoverableFileDelete(String file_name)
|
void |
ping(InetAddress interface_address,
InetAddress target,
PlatformManagerPingCallback callback)
|
void |
registerAdditionalFileType(String name,
String description,
String type,
String content_type)
Registers a file type with this application |
void |
registerAdditionalFileType(String name,
String description,
String type,
String content_type,
boolean url_protocol)
|
void |
registerApplication()
|
protected void |
registerBC()
|
protected void |
registerDHT()
|
protected void |
registerMagnet(boolean force)
|
void |
removeListener(PlatformManagerListener listener)
|
void |
requestUserAttention(int type,
Object data)
Requests the user's attention such as bouncing the application icon on OSX |
void |
setExplicitVMOptions(String[] options)
|
void |
setPreventComputerSleep(boolean prevent_it)
|
void |
setRunAtLogin(boolean run)
|
void |
setTCPTOSEnabled(boolean enabled)
enable or disable the platforms support for TCP TOS |
int |
shellExecute(String operation,
String file,
String parameters,
String directory,
int SW_const)
|
void |
showFile(String file_name)
Reveals the file or directory with the platform's default browser |
void |
shutdown(int type)
|
void |
startup(AzureusCore azureus_core)
|
boolean |
testNativeAvailability(String name)
|
void |
traceRoute(InetAddress interface_address,
InetAddress target,
PlatformManagerPingCallback callback)
|
void |
unregisterAdditionalFileType(String name,
String type)
Removes a file-type registration |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int RT_NONE
public static final int RT_AZ
public static final int RT_OTHER
public static String DLL_NAME
public static final String VUZE_ASSOC
public static final String NEW_MAIN_ASSOC
public static final String OLD_MAIN_ASS0C
Constructor Detail |
---|
protected PlatformManagerImpl() throws PlatformManagerException
PlatformManagerException
Method Detail |
---|
public static PlatformManagerImpl getSingleton() throws PlatformManagerException
PlatformManagerException
protected void applyPatches()
protected void fixPermissions(File parent, File dir) throws PlatformManagerException
PlatformManagerException
protected int getIconIndex() throws PlatformManagerException
PlatformManagerException
public String getVersion()
protected File getApplicationEXELocation() throws PlatformManagerException
PlatformManagerException
public int getPlatformType()
public String getUserDataDirectory() throws PlatformManagerException
PlatformManagerException
public String getComputerName()
getComputerName
in interface PlatformManager
public File getLocation(long location_id) throws PlatformManagerException
PlatformManager
getLocation
in interface PlatformManager
location_id
- from above LOC_constants
PlatformManagerException
public File getVMOptionFile() throws PlatformManagerException
PlatformManagerException
public String[] getExplicitVMOptions() throws PlatformManagerException
PlatformManagerException
public void setExplicitVMOptions(String[] options) throws PlatformManagerException
PlatformManagerException
public boolean getRunAtLogin() throws PlatformManagerException
PlatformManagerException
public void setRunAtLogin(boolean run) throws PlatformManagerException
PlatformManagerException
public int getShutdownTypes()
public boolean getPreventComputerSleep()
public void setPreventComputerSleep(boolean prevent_it)
public void startup(AzureusCore azureus_core) throws PlatformManagerException
PlatformManagerException
public void shutdown(int type) throws PlatformManagerException
PlatformManagerException
public String getApplicationCommandLine()
public boolean isApplicationRegistered() throws PlatformManagerException
PlatformManagerException
protected void checkExeKey(File exe)
protected void checkExeKey(int hkey, File exe)
public boolean isAdditionalFileTypeRegistered(String name, String type) throws PlatformManagerException
PlatformManager
isAdditionalFileTypeRegistered
in interface PlatformManager
PlatformManagerException
public int getAdditionalFileTypeRegistrationDetails(String name, String type) throws PlatformManagerException
PlatformManagerException
public void registerApplication() throws PlatformManagerException
PlatformManagerException
protected void registerMagnet(boolean force)
protected boolean createKey(int type, String key)
protected void registerDHT()
protected void registerBC()
public void registerAdditionalFileType(String name, String description, String type, String content_type) throws PlatformManagerException
PlatformManager
registerAdditionalFileType
in interface PlatformManager
PlatformManagerException
public void registerAdditionalFileType(String name, String description, String type, String content_type, boolean url_protocol) throws PlatformManagerException
PlatformManagerException
public void unregisterAdditionalFileType(String name, String type) throws PlatformManagerException
PlatformManager
unregisterAdditionalFileType
in interface PlatformManager
PlatformManagerException
public void createProcess(String command_line, boolean inherit_handles) throws PlatformManagerException
PlatformManagerException
public void performRecoverableFileDelete(String file_name) throws PlatformManagerException
PlatformManagerException
public void setTCPTOSEnabled(boolean enabled) throws PlatformManagerException
PlatformManager
PlatformManagerException
public void copyFilePermissions(String from_file_name, String to_file_name) throws PlatformManagerException
PlatformManagerException
public void showFile(String file_name) throws PlatformManagerException
showFile
in interface PlatformManager
file_name
- The full path to a file or directory
PlatformManagerException
- If this operation failspublic boolean testNativeAvailability(String name) throws PlatformManagerException
PlatformManagerException
public void traceRoute(InetAddress interface_address, InetAddress target, PlatformManagerPingCallback callback) throws PlatformManagerException
PlatformManagerException
public void ping(InetAddress interface_address, InetAddress target, PlatformManagerPingCallback callback) throws PlatformManagerException
PlatformManagerException
public int shellExecute(String operation, String file, String parameters, String directory, int SW_const) throws PlatformManagerException
PlatformManagerException
public int getMaxOpenFiles() throws PlatformManagerException
PlatformManager
PlatformManagerException
public boolean hasCapability(PlatformManagerCapabilities capability)
Gets whether the platform manager supports a capability
Users of PlatformManager should check for supported capabilities before calling the corresponding methods
Note that support for a particular capability may change arbitrarily in the duration of the application session, but the manager will cache where necessary.
capability
- A platform manager capability
public void dispose()
public int eventOccurred(int type)
eventOccurred
in interface AEWin32AccessListener
public void addListener(PlatformManagerListener listener)
public void removeListener(PlatformManagerListener listener)
public void requestUserAttention(int type, Object data) throws PlatformManagerException
PlatformManager
PlatformManagerException
public Class<?> loadClass(ClassLoader loader, String class_name) throws PlatformManagerException
PlatformManager
PlatformManagerException
public void generate(IndentWriter writer)
generate
in interface AEDiagnosticsEvidenceGenerator
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |