com.ibm.di.connector.sapr3.user
Class AbapErrorInfo

java.lang.Object
  extended by com.ibm.di.connector.sapr3.user.AbapErrorInfo

public final class AbapErrorInfo
extends Object

This class represents an instance of BAPI RFC Return structure information.


Constructor Summary
AbapErrorInfo(String message, String errorNum, String severityFlag)
          Create a new instance.
 
Method Summary
 String getInternalSource()
          Miscellaneous context information.
 String getMsg()
          Get the message string.
 Integer getMsgNum()
          Get the message number.
 boolean isError()
          Get the error indicator.
 boolean isMissingUserError()
          Convenience method to determine if error indicates that the specified user does not exist.
 boolean isWarn()
          Get the warning indicator.
 void setInternalSource(String s)
          Miscellaneous context information.
 String toString()
          Make string representation of this instance.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AbapErrorInfo

public AbapErrorInfo(String message,
                     String errorNum,
                     String severityFlag)
              throws IllegalArgumentException
Create a new instance.

Parameters:
message - The message returned from SAP RFC.
errorNum - The error number indicator.
severityFlag - The severity indicator from the RFC.
Throws:
IllegalArgumentException - if any params are null.
Method Detail

getMsg

public String getMsg()
Get the message string.

Returns:
The message.

getMsgNum

public Integer getMsgNum()
Get the message number.

Returns:
The message number.

isError

public boolean isError()
Get the error indicator.

Returns:
true if ABAP error was returned, false otherwise.

isWarn

public boolean isWarn()
Get the warning indicator.

Returns:
true if ABAP warning was returned, false otherwise.

setInternalSource

public void setInternalSource(String s)
Miscellaneous context information.

Parameters:
s - The value.

getInternalSource

public String getInternalSource()
Miscellaneous context information.

Returns:
s The value.

isMissingUserError

public boolean isMissingUserError()
Convenience method to determine if error indicates that the specified user does not exist.

Returns:
true if getMsgNum() == 124.

toString

public String toString()
Make string representation of this instance.

Overrides:
toString in class Object
Returns:
A formatted string of the as follows: {SEVERITY}: {MESSAGE} {(ERROR_NUMBER)} {(CONTEXT)}.