Top Description Fields Constructors Methods
com.sun.jna.platform.win32.COM

public Class COMInvokeException

extends COMException
Class Inheritance
Imports
com.sun.jna.platform.win32.WinError, .WinNT.HRESULT

Exception class for error origination from an COM invoke

Field Summary

Modifier and TypeField and Description
private final String
private final Integer
private final Integer
private final String
private final Integer
private static final long
private final String
private final Integer

Constructor Summary

AccessConstructor and Description
public
COMInvokeException()

Instantiates a new automation exception.

public
COMInvokeException(String
the message
message
)

Instantiates a new automation exception.

public
COMInvokeException(Throwable
the cause
cause
)

Instantiates a new automation exception.

public
COMInvokeException(String
the message
message
,
Throwable
the cause
cause
)

Instantiates a new automation exception.

public
COMInvokeException(String
exception message
message
,
WinNT.HRESULT
hresult of the invoke call
hresult
,
Integer
the position of the argument that caused the error
errorArg
,
String
The exception description to display. If no description is available, use null.
description
,
Integer
The help context ID.
helpContext
,
String
The fully qualified help file path. If no Help is available, use null.
helpFile
,
Integer
A return value that describes the error. Either this field or wCode (but not both) must be filled in; the other must be set to 0. (16-bit Windows versions only.)
scode
,
String
The name of the exception source. Typically, this is an application name. This field should be filled in by the implementor of IDispatch.
source
,
Integer
The error code. Error codes should be greater than 1000. Either this field or the scode field must be filled in; the other must be set to 0.
wCode
)

Instantiates a new automation exception.

Method Summary

Modifier and TypeMethod and Description
private static String
formatMessage(WinNT.HRESULT hresult, String message, Integer errArg)

public String

Returns:

The exception description to display. If no description is available, use null.
getDescription
()

public Integer

Returns:

the arg err
getErrorArg
()

Gets the arg err.

public Integer

Returns:

The help context ID or NULL if not present
getHelpContext
()

public String

Returns:

The fully qualified help file path. If no Help is available, use null.
getHelpFile
()

public Integer

Returns:

A return value that describes the error. Either this field or wCode (but not both) must be filled in; the other must be set to 0. (16-bit Windows versions only.) NULL if no exception info was created.
getScode
()

public String

Returns:

The name of the exception source. Typically, this is an application name. This field should be filled in by the implementor of IDispatch. NULL if no exception info was created
getSource
()

public Integer

Returns:

The error code. Error codes should be greater than 1000. Either this field or the scode field must be filled in; the other must be set to 0. It is NULL if no exception info was created
getWCode
()

Inherited from com.sun.jna.platform.win32.COM.COMException:
getHresultmatchesErrorCode

Field Detail

descriptionback to summary
private final String description
errorArgback to summary
private final Integer errorArg
helpContextback to summary
private final Integer helpContext
helpFileback to summary
private final String helpFile
scodeback to summary
private final Integer scode
serialVersionUIDback to summary
private static final long serialVersionUID

Hides com.sun.jna.platform.win32.COM.COMException.serialVersionUID.

sourceback to summary
private final String source
wCodeback to summary
private final Integer wCode

Constructor Detail

COMInvokeExceptionback to summary
public COMInvokeException()

Instantiates a new automation exception.

COMInvokeExceptionback to summary
public COMInvokeException(String message)

Instantiates a new automation exception.

Parameters
message:String

the message

COMInvokeExceptionback to summary
public COMInvokeException(Throwable cause)

Instantiates a new automation exception.

Parameters
cause:Throwable

the cause

COMInvokeExceptionback to summary
public COMInvokeException(String message, Throwable cause)

Instantiates a new automation exception.

Parameters
message:String

the message

cause:Throwable

the cause

COMInvokeExceptionback to summary
public COMInvokeException(String message, WinNT.HRESULT hresult, Integer errorArg, String description, Integer helpContext, String helpFile, Integer scode, String source, Integer wCode)

Instantiates a new automation exception.

Parameters
message:String

exception message

hresult:WinNT.HRESULT

hresult of the invoke call

errorArg:Integer

the position of the argument that caused the error

description:String

The exception description to display. If no description is available, use null.

helpContext:Integer

The help context ID.

helpFile:String

The fully qualified help file path. If no Help is available, use null.

scode:Integer

A return value that describes the error. Either this field or wCode (but not both) must be filled in; the other must be set to 0. (16-bit Windows versions only.)

source:String

The name of the exception source. Typically, this is an application name. This field should be filled in by the implementor of IDispatch.

wCode:Integer

The error code. Error codes should be greater than 1000. Either this field or the scode field must be filled in; the other must be set to 0.

Method Detail

formatMessageback to summary
private static String formatMessage(WinNT.HRESULT hresult, String message, Integer errArg)
getDescriptionback to summary
public String getDescription()
Returns:String

The exception description to display. If no description is available, use null.

getErrorArgback to summary
public Integer getErrorArg()

Gets the arg err.

Returns:Integer

the arg err

getHelpContextback to summary
public Integer getHelpContext()
Returns:Integer

The help context ID or NULL if not present

getHelpFileback to summary
public String getHelpFile()
Returns:String

The fully qualified help file path. If no Help is available, use null.

getScodeback to summary
public Integer getScode()
Returns:Integer

A return value that describes the error. Either this field or wCode (but not both) must be filled in; the other must be set to 0. (16-bit Windows versions only.) NULL if no exception info was created.

getSourceback to summary
public String getSource()
Returns:String

The name of the exception source. Typically, this is an application name. This field should be filled in by the implementor of IDispatch. NULL if no exception info was created

getWCodeback to summary
public Integer getWCode()
Returns:Integer

The error code. Error codes should be greater than 1000. Either this field or the scode field must be filled in; the other must be set to 0. It is NULL if no exception info was created