Package com.sun.jna.platform.win32
Class Rasapi32Util
java.lang.Object
com.sun.jna.platform.win32.Rasapi32Util
Rasapi32 utility API.
- 
Nested Class SummaryNested Classes
- 
Field SummaryFields
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionstatic WinNT.HANDLEDial a phone book entry by name (Synchronously)static WinNT.HANDLEdialEntry(String entryName, WinRas.RasDialFunc2 func2) Dial a phone book entry by name (Asynchronously - callback type 2)static WinRas.RASPPPIPgetIPProjection(WinNT.HANDLE hrasConn) Get the connection's IP projectionstatic WinRas.RASDIALPARAMSgetPhoneBookDialingParams(String entryName) get a phone book entry's dialing parametersstatic WinRas.RASENTRY.ByReferencegetPhoneBookEntry(String entryName) Return the phone book entry.static WinNT.HANDLEgetRasConnection(String connName) Return a RAS connection by namestatic StringgetRasConnectionStatusText(int connStatus) Translate the connection status value to textstatic StringgetRasErrorString(int code) Get the RAS error descriptionstatic voidhangupRasConnection(WinNT.HANDLE hrasConn) Hangup a connectionstatic voidhangupRasConnection(String connName) Hangup a connection by namestatic voidsetPhoneBookEntry(String entryName, WinRas.RASENTRY.ByReference rasEntry) Set a phone book entry
- 
Field Details- 
CONNECTION_STATE_TEXT
 
- 
- 
Constructor Details- 
Rasapi32Utilpublic Rasapi32Util()
 
- 
- 
Method Details- 
getRasErrorStringGet the RAS error description- Parameters:
- code- the error code
- Returns:
- the RAS description
 
- 
getRasConnectionStatusTextTranslate the connection status value to text- Parameters:
- connStatus- the connection status
- Returns:
- the descriptive text
 
- 
getRasConnectionReturn a RAS connection by name- Parameters:
- connName- the connection name
- Returns:
- the RAS connection structure
- Throws:
- Rasapi32Util.Ras32Exception- errors
 
- 
hangupRasConnectionHangup a connection by name- Parameters:
- connName- the connection name
- Throws:
- Rasapi32Util.Ras32Exception- errors
 
- 
hangupRasConnectionHangup a connection- Parameters:
- hrasConn- the connection
- Throws:
- Rasapi32Util.Ras32Exception- errors
 
- 
getIPProjectionpublic static WinRas.RASPPPIP getIPProjection(WinNT.HANDLE hrasConn) throws Rasapi32Util.Ras32Exception Get the connection's IP projection- Parameters:
- hrasConn- the RAS connection handle
- Returns:
- the IP projection
- Throws:
- Rasapi32Util.Ras32Exception- errors
 
- 
getPhoneBookEntrypublic static WinRas.RASENTRY.ByReference getPhoneBookEntry(String entryName) throws Rasapi32Util.Ras32Exception Return the phone book entry.- Parameters:
- entryName- the entry name
- Returns:
- the RAS entry
- Throws:
- Rasapi32Util.Ras32Exception- any errors
 
- 
setPhoneBookEntrypublic static void setPhoneBookEntry(String entryName, WinRas.RASENTRY.ByReference rasEntry) throws Rasapi32Util.Ras32Exception Set a phone book entry- Parameters:
- entryName- the phone book entry name
- rasEntry- the entry parameters
- Throws:
- Rasapi32Util.Ras32Exception- errors
 
- 
getPhoneBookDialingParamspublic static WinRas.RASDIALPARAMS getPhoneBookDialingParams(String entryName) throws Rasapi32Util.Ras32Exception get a phone book entry's dialing parameters- Parameters:
- entryName- the phone book entry name
- Returns:
- the entry's dialing parameters parameters
- Throws:
- Rasapi32Util.Ras32Exception- errors
 
- 
dialEntryDial a phone book entry by name (Synchronously)- Parameters:
- entryName- The phone book entry name
- Returns:
- result reference
- Throws:
- Rasapi32Util.Ras32Exception- errors
 
- 
dialEntrypublic static WinNT.HANDLE dialEntry(String entryName, WinRas.RasDialFunc2 func2) throws Rasapi32Util.Ras32Exception Dial a phone book entry by name (Asynchronously - callback type 2)- Parameters:
- entryName- The phone book entry name
- func2-
- Returns:
- the HRASCONN for this connection
- Throws:
- Rasapi32Util.Ras32Exception- errors
 
 
-