Module jcifs

Class NbtException

All Implemented Interfaces:
Serializable

public class NbtException extends CIFSException
NetBIOS exception class for NBT-related errors. This exception encapsulates NetBIOS name service and session service errors with specific error classes and codes.
See Also:
  • Field Details

    • SUCCESS

      public static final int SUCCESS
      Success status code
      See Also:
    • ERR_NAM_SRVC

      public static final int ERR_NAM_SRVC
      Name service error class
      See Also:
    • ERR_SSN_SRVC

      public static final int ERR_SSN_SRVC
      Session service error class
      See Also:
    • FMT_ERR

      public static final int FMT_ERR
      Format error in the name service
      See Also:
    • SRV_ERR

      public static final int SRV_ERR
      Server error in the name service
      See Also:
    • IMP_ERR

      public static final int IMP_ERR
      Implementation error in the name service
      See Also:
    • RFS_ERR

      public static final int RFS_ERR
      Refused error in the name service
      See Also:
    • ACT_ERR

      public static final int ACT_ERR
      Active error in the name service
      See Also:
    • CFT_ERR

      public static final int CFT_ERR
      Name in conflict error
      See Also:
    • CONNECTION_REFUSED

      public static final int CONNECTION_REFUSED
      Connection refused by the remote host
      See Also:
    • NOT_LISTENING_CALLED

      public static final int NOT_LISTENING_CALLED
      Not listening on the called name
      See Also:
    • NOT_LISTENING_CALLING

      public static final int NOT_LISTENING_CALLING
      Not listening for the calling name
      See Also:
    • CALLED_NOT_PRESENT

      public static final int CALLED_NOT_PRESENT
      Called name not present
      See Also:
    • NO_RESOURCES

      public static final int NO_RESOURCES
      Insufficient resources to establish session
      See Also:
    • UNSPECIFIED

      public static final int UNSPECIFIED
      Unspecified session service error
      See Also:
    • errorClass

      public int errorClass
      The NetBIOS error class
    • errorCode

      public int errorCode
      The NetBIOS error code
  • Constructor Details

    • NbtException

      public NbtException(int errorClass, int errorCode)
      Constructs an NbtException with the specified error class and code.
      Parameters:
      errorClass - the NetBIOS error class
      errorCode - the NetBIOS error code
  • Method Details

    • getErrorString

      public static String getErrorString(int errorClass, int errorCode)
      Converts NetBIOS error class and code to a human-readable string.
      Parameters:
      errorClass - the error class
      errorCode - the error code
      Returns:
      a descriptive error string
    • toString

      public String toString()
      Overrides:
      toString in class Throwable