Package org.apache.tomcat.jni
Class Registry
- java.lang.Object
- 
- org.apache.tomcat.jni.Registry
 
- 
 @Deprecated public class Registry extends java.lang.ObjectDeprecated.The scope of the APR/Native Library will be reduced in Tomcat 10.1.x / Tomcat Native 2.x onwards to only include those components required to provide OpenSSL integration with the NIO and NIO2 connectors.Windows Registry support- Author:
- Mladen Turk
 
- 
- 
Field SummaryFields Modifier and Type Field Description static intHKEY_CLASSES_ROOTDeprecated.static intHKEY_CURRENT_CONFIGDeprecated.static intHKEY_CURRENT_USERDeprecated.static intHKEY_LOCAL_MACHINEDeprecated.static intHKEY_USERSDeprecated.static intKEY_ALL_ACCESSDeprecated.static intKEY_CREATE_LINKDeprecated.static intKEY_CREATE_SUB_KEYDeprecated.static intKEY_ENUMERATE_SUB_KEYSDeprecated.static intKEY_EXECUTEDeprecated.static intKEY_NOTIFYDeprecated.static intKEY_QUERY_VALUEDeprecated.static intKEY_READDeprecated.static intKEY_SET_VALUEDeprecated.static intKEY_WOW64_32KEYDeprecated.static intKEY_WOW64_64KEYDeprecated.static intKEY_WRITEDeprecated.static intREG_BINARYDeprecated.static intREG_DWORDDeprecated.static intREG_EXPAND_SZDeprecated.static intREG_MULTI_SZDeprecated.static intREG_QWORDDeprecated.static intREG_SZDeprecated.
 - 
Constructor SummaryConstructors Constructor Description Registry()Deprecated.
 - 
Method SummaryAll Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static intclose(long key)Deprecated.Close the specified Registry key.static longcreate(int root, java.lang.String name, int sam, long pool)Deprecated.Create or open a Registry Key.static intdeleteKey(int root, java.lang.String name, boolean onlyIfEmpty)Deprecated.Delete the Registry subkeystatic intdeleteValue(long key, java.lang.String name)Deprecated.Delete the Registry valuestatic java.lang.String[]enumKeys(long key)Deprecated.Enumerate the Registry subkeysstatic java.lang.String[]enumValues(long key)Deprecated.Enumerate the Registry valuesstatic intgetSize(long key, java.lang.String name)Deprecated.Get the Registry key length.static intgetType(long key, java.lang.String name)Deprecated.Get the Registry key type.static java.lang.String[]getValueA(long key, java.lang.String name)Deprecated.Get the Registry value for REG_MULTI_SZstatic byte[]getValueB(long key, java.lang.String name)Deprecated.Get the Registry value for REG_BINARYstatic intgetValueI(long key, java.lang.String name)Deprecated.Get the Registry value for REG_DWORDstatic longgetValueJ(long key, java.lang.String name)Deprecated.Get the Registry value for REG_QWORD or REG_DWORDstatic java.lang.StringgetValueS(long key, java.lang.String name)Deprecated.Get the Registry value for REG_SZ or REG_EXPAND_SZstatic longopen(int root, java.lang.String name, int sam, long pool)Deprecated.Opens the specified Registry Key.static intsetValueA(long key, java.lang.String name, java.lang.String[] val)Deprecated.Set the Registry value for REG_MULTI_SZstatic intsetValueB(long key, java.lang.String name, byte[] val)Deprecated.Set the Registry value for REG_BINARYstatic intsetValueE(long key, java.lang.String name, java.lang.String val)Deprecated.Set the Registry value for REG_EXPAND_SZstatic intsetValueI(long key, java.lang.String name, int val)Deprecated.Set the Registry value for REG_DWORDstatic intsetValueJ(long key, java.lang.String name, long val)Deprecated.Set the Registry value for REG_QWORDstatic intsetValueS(long key, java.lang.String name, java.lang.String val)Deprecated.Set the Registry value for REG_SZ
 
- 
- 
- 
Field Detail- 
HKEY_CLASSES_ROOTpublic static final int HKEY_CLASSES_ROOT Deprecated.- See Also:
- Constant Field Values
 
 - 
HKEY_CURRENT_CONFIGpublic static final int HKEY_CURRENT_CONFIG Deprecated.- See Also:
- Constant Field Values
 
 - 
HKEY_CURRENT_USERpublic static final int HKEY_CURRENT_USER Deprecated.- See Also:
- Constant Field Values
 
 - 
HKEY_LOCAL_MACHINEpublic static final int HKEY_LOCAL_MACHINE Deprecated.- See Also:
- Constant Field Values
 
 - 
HKEY_USERSpublic static final int HKEY_USERS Deprecated.- See Also:
- Constant Field Values
 
 - 
KEY_ALL_ACCESSpublic static final int KEY_ALL_ACCESS Deprecated.- See Also:
- Constant Field Values
 
 - 
KEY_CREATE_LINKpublic static final int KEY_CREATE_LINK Deprecated.- See Also:
- Constant Field Values
 
 - 
KEY_CREATE_SUB_KEYpublic static final int KEY_CREATE_SUB_KEY Deprecated.- See Also:
- Constant Field Values
 
 - 
KEY_ENUMERATE_SUB_KEYSpublic static final int KEY_ENUMERATE_SUB_KEYS Deprecated.- See Also:
- Constant Field Values
 
 - 
KEY_EXECUTEpublic static final int KEY_EXECUTE Deprecated.- See Also:
- Constant Field Values
 
 - 
KEY_NOTIFYpublic static final int KEY_NOTIFY Deprecated.- See Also:
- Constant Field Values
 
 - 
KEY_QUERY_VALUEpublic static final int KEY_QUERY_VALUE Deprecated.- See Also:
- Constant Field Values
 
 - 
KEY_READpublic static final int KEY_READ Deprecated.- See Also:
- Constant Field Values
 
 - 
KEY_SET_VALUEpublic static final int KEY_SET_VALUE Deprecated.- See Also:
- Constant Field Values
 
 - 
KEY_WOW64_64KEYpublic static final int KEY_WOW64_64KEY Deprecated.- See Also:
- Constant Field Values
 
 - 
KEY_WOW64_32KEYpublic static final int KEY_WOW64_32KEY Deprecated.- See Also:
- Constant Field Values
 
 - 
KEY_WRITEpublic static final int KEY_WRITE Deprecated.- See Also:
- Constant Field Values
 
 - 
REG_BINARYpublic static final int REG_BINARY Deprecated.- See Also:
- Constant Field Values
 
 - 
REG_DWORDpublic static final int REG_DWORD Deprecated.- See Also:
- Constant Field Values
 
 - 
REG_EXPAND_SZpublic static final int REG_EXPAND_SZ Deprecated.- See Also:
- Constant Field Values
 
 - 
REG_MULTI_SZpublic static final int REG_MULTI_SZ Deprecated.- See Also:
- Constant Field Values
 
 - 
REG_QWORDpublic static final int REG_QWORD Deprecated.- See Also:
- Constant Field Values
 
 - 
REG_SZpublic static final int REG_SZ Deprecated.- See Also:
- Constant Field Values
 
 
- 
 - 
Method Detail- 
createpublic static long create(int root, java.lang.String name, int sam, long pool) throws ErrorDeprecated.Create or open a Registry Key.- Parameters:
- name- Registry Subkey to open
- root- Root key, one of HKEY_*
- sam- Access mask that specifies the access rights for the key.
- pool- Pool used for native memory allocation
- Returns:
- Opened Registry key
- Throws:
- Error- An error occurred
 
 - 
openpublic static long open(int root, java.lang.String name, int sam, long pool) throws ErrorDeprecated.Opens the specified Registry Key.- Parameters:
- name- Registry Subkey to open
- root- Root key, one of HKEY_*
- sam- Access mask that specifies the access rights for the key.
- pool- Pool used for native memory allocation
- Returns:
- Opened Registry key
- Throws:
- Error- An error occurred
 
 - 
closepublic static int close(long key) Deprecated.Close the specified Registry key.- Parameters:
- key- The Registry key descriptor to close.
- Returns:
- the operation status
 
 - 
getTypepublic static int getType(long key, java.lang.String name)Deprecated.Get the Registry key type.- Parameters:
- key- The Registry key descriptor to use.
- name- The name of the value to query
- Returns:
- Value type or negative error value
 
 - 
getValueIpublic static int getValueI(long key, java.lang.String name) throws ErrorDeprecated.Get the Registry value for REG_DWORD- Parameters:
- key- The Registry key descriptor to use.
- name- The name of the value to query
- Returns:
- Registry key value
- Throws:
- Error- An error occurred
 
 - 
getValueJpublic static long getValueJ(long key, java.lang.String name) throws ErrorDeprecated.Get the Registry value for REG_QWORD or REG_DWORD- Parameters:
- key- The Registry key descriptor to use.
- name- The name of the value to query
- Returns:
- Registry key value
- Throws:
- Error- An error occurred
 
 - 
getSizepublic static int getSize(long key, java.lang.String name)Deprecated.Get the Registry key length.- Parameters:
- key- The Registry key descriptor to use.
- name- The name of the value to query
- Returns:
- Value size or negative error value
 
 - 
getValueSpublic static java.lang.String getValueS(long key, java.lang.String name) throws ErrorDeprecated.Get the Registry value for REG_SZ or REG_EXPAND_SZ- Parameters:
- key- The Registry key descriptor to use.
- name- The name of the value to query
- Returns:
- Registry key value
- Throws:
- Error- An error occurred
 
 - 
getValueApublic static java.lang.String[] getValueA(long key, java.lang.String name) throws ErrorDeprecated.Get the Registry value for REG_MULTI_SZ- Parameters:
- key- The Registry key descriptor to use.
- name- The name of the value to query
- Returns:
- Registry key value
- Throws:
- Error- An error occurred
 
 - 
getValueBpublic static byte[] getValueB(long key, java.lang.String name) throws ErrorDeprecated.Get the Registry value for REG_BINARY- Parameters:
- key- The Registry key descriptor to use.
- name- The name of the value to query
- Returns:
- Registry key value
- Throws:
- Error- An error occurred
 
 - 
setValueIpublic static int setValueI(long key, java.lang.String name, int val)Deprecated.Set the Registry value for REG_DWORD- Parameters:
- key- The Registry key descriptor to use.
- name- The name of the value to set
- val- The the value to set
- Returns:
- If the function succeeds, the return value is 0
 
 - 
setValueJpublic static int setValueJ(long key, java.lang.String name, long val)Deprecated.Set the Registry value for REG_QWORD- Parameters:
- key- The Registry key descriptor to use.
- name- The name of the value to set
- val- The the value to set
- Returns:
- If the function succeeds, the return value is 0
 
 - 
setValueSpublic static int setValueS(long key, java.lang.String name, java.lang.String val)Deprecated.Set the Registry value for REG_SZ- Parameters:
- key- The Registry key descriptor to use.
- name- The name of the value to set
- val- The the value to set
- Returns:
- If the function succeeds, the return value is 0
 
 - 
setValueEpublic static int setValueE(long key, java.lang.String name, java.lang.String val)Deprecated.Set the Registry value for REG_EXPAND_SZ- Parameters:
- key- The Registry key descriptor to use.
- name- The name of the value to set
- val- The the value to set
- Returns:
- If the function succeeds, the return value is 0
 
 - 
setValueApublic static int setValueA(long key, java.lang.String name, java.lang.String[] val)Deprecated.Set the Registry value for REG_MULTI_SZ- Parameters:
- key- The Registry key descriptor to use.
- name- The name of the value to set
- val- The the value to set
- Returns:
- If the function succeeds, the return value is 0
 
 - 
setValueBpublic static int setValueB(long key, java.lang.String name, byte[] val)Deprecated.Set the Registry value for REG_BINARY- Parameters:
- key- The Registry key descriptor to use.
- name- The name of the value to set
- val- The the value to set
- Returns:
- If the function succeeds, the return value is 0
 
 - 
enumKeyspublic static java.lang.String[] enumKeys(long key) throws ErrorDeprecated.Enumerate the Registry subkeys- Parameters:
- key- The Registry key descriptor to use.
- Returns:
- Array of all subkey names
- Throws:
- Error- An error occurred
 
 - 
enumValuespublic static java.lang.String[] enumValues(long key) throws ErrorDeprecated.Enumerate the Registry values- Parameters:
- key- The Registry key descriptor to use.
- Returns:
- Array of all value names
- Throws:
- Error- An error occurred
 
 - 
deleteValuepublic static int deleteValue(long key, java.lang.String name)Deprecated.Delete the Registry value- Parameters:
- key- The Registry key descriptor to use.
- name- The name of the value to delete
- Returns:
- If the function succeeds, the return value is 0
 
 - 
deleteKeypublic static int deleteKey(int root, java.lang.String name, boolean onlyIfEmpty)Deprecated.Delete the Registry subkey- Parameters:
- root- Root key, one of HKEY_*
- name- Subkey to delete
- onlyIfEmpty- If true will not delete a key if it contains any subkeys or values
- Returns:
- If the function succeeds, the return value is 0
 
 
- 
 
-