public class com.mongodb.MongoCommandException extends com.mongodb.MongoServerException
  minor version: 0
  major version: 59
  flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
  this_class: com.mongodb.MongoCommandException
  super_class: com.mongodb.MongoServerException
{
  private static final long serialVersionUID;
    descriptor: J
    flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
    ConstantValue: 8160676451944215078

  private final org.bson.BsonDocument response;
    descriptor: Lorg/bson/BsonDocument;
    flags: (0x0012) ACC_PRIVATE, ACC_FINAL

  public void <init>(org.bson.BsonDocument, com.mongodb.ServerAddress);
    descriptor: (Lorg/bson/BsonDocument;Lcom/mongodb/ServerAddress;)V
    flags: (0x0001) ACC_PUBLIC
    Code:
      stack=7, locals=5, args_size=3
        start local 0 // com.mongodb.MongoCommandException this
        start local 1 // org.bson.BsonDocument response
        start local 2 // com.mongodb.ServerAddress address
         0: .line 49
            aload 0 /* this */
            aload 1 /* response */
            invokestatic com.mongodb.MongoCommandException.extractErrorCode:(Lorg/bson/BsonDocument;)I
         1: .line 50
            ldc "Command failed with error %s: '%s' on server %s. The full response is %s"
            iconst_4
            anewarray java.lang.Object
            dup
            iconst_0
            aload 1 /* response */
            invokestatic com.mongodb.MongoCommandException.extractErrorCodeAndName:(Lorg/bson/BsonDocument;)Ljava/lang/String;
            aastore
            dup
            iconst_1
         2: .line 51
            aload 1 /* response */
            invokestatic com.mongodb.MongoCommandException.extractErrorMessage:(Lorg/bson/BsonDocument;)Ljava/lang/String;
            aastore
            dup
            iconst_2
            aload 2 /* address */
            aastore
            dup
            iconst_3
            aload 1 /* response */
            invokestatic com.mongodb.MongoCommandException.getResponseAsJson:(Lorg/bson/BsonDocument;)Ljava/lang/String;
            aastore
         3: .line 50
            invokestatic java.lang.String.format:(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
         4: .line 51
            aload 2 /* address */
            invokespecial com.mongodb.MongoServerException.<init>:(ILjava/lang/String;Lcom/mongodb/ServerAddress;)V
         5: .line 52
            aload 0 /* this */
            aload 1 /* response */
            putfield com.mongodb.MongoCommandException.response:Lorg/bson/BsonDocument;
         6: .line 53
            aload 1 /* response */
            ldc "errorLabels"
            new org.bson.BsonArray
            dup
            invokespecial org.bson.BsonArray.<init>:()V
            invokevirtual org.bson.BsonDocument.getArray:(Ljava/lang/Object;Lorg/bson/BsonArray;)Lorg/bson/BsonArray;
            invokevirtual org.bson.BsonArray.iterator:()Ljava/util/Iterator;
            astore 4
            goto 9
      StackMap locals: com.mongodb.MongoCommandException org.bson.BsonDocument com.mongodb.ServerAddress top java.util.Iterator
      StackMap stack:
         7: aload 4
            invokeinterface java.util.Iterator.next:()Ljava/lang/Object;
            checkcast org.bson.BsonValue
            astore 3 /* curErrorLabel */
        start local 3 // org.bson.BsonValue curErrorLabel
         8: .line 54
            aload 0 /* this */
            aload 3 /* curErrorLabel */
            invokevirtual org.bson.BsonValue.asString:()Lorg/bson/BsonString;
            invokevirtual org.bson.BsonString.getValue:()Ljava/lang/String;
            invokevirtual com.mongodb.MongoCommandException.addLabel:(Ljava/lang/String;)V
        end local 3 // org.bson.BsonValue curErrorLabel
         9: .line 53
      StackMap locals:
      StackMap stack:
            aload 4
            invokeinterface java.util.Iterator.hasNext:()Z
            ifne 7
        10: .line 56
            return
        end local 2 // com.mongodb.ServerAddress address
        end local 1 // org.bson.BsonDocument response
        end local 0 // com.mongodb.MongoCommandException this
      LocalVariableTable:
        Start  End  Slot           Name  Signature
            0   11     0           this  Lcom/mongodb/MongoCommandException;
            0   11     1       response  Lorg/bson/BsonDocument;
            0   11     2        address  Lcom/mongodb/ServerAddress;
            8    9     3  curErrorLabel  Lorg/bson/BsonValue;
    MethodParameters:
          Name  Flags
      response  final
      address   final

  public int getErrorCode();
    descriptor: ()I
    flags: (0x0001) ACC_PUBLIC
    Code:
      stack=1, locals=1, args_size=1
        start local 0 // com.mongodb.MongoCommandException this
         0: .line 64
            aload 0 /* this */
            invokevirtual com.mongodb.MongoCommandException.getCode:()I
            ireturn
        end local 0 // com.mongodb.MongoCommandException this
      LocalVariableTable:
        Start  End  Slot  Name  Signature
            0    1     0  this  Lcom/mongodb/MongoCommandException;

  public java.lang.String getErrorCodeName();
    descriptor: ()Ljava/lang/String;
    flags: (0x0001) ACC_PUBLIC
    Code:
      stack=1, locals=1, args_size=1
        start local 0 // com.mongodb.MongoCommandException this
         0: .line 75
            aload 0 /* this */
            getfield com.mongodb.MongoCommandException.response:Lorg/bson/BsonDocument;
            invokestatic com.mongodb.MongoCommandException.extractErrorCodeName:(Lorg/bson/BsonDocument;)Ljava/lang/String;
            areturn
        end local 0 // com.mongodb.MongoCommandException this
      LocalVariableTable:
        Start  End  Slot  Name  Signature
            0    1     0  this  Lcom/mongodb/MongoCommandException;

  public java.lang.String getErrorMessage();
    descriptor: ()Ljava/lang/String;
    flags: (0x0001) ACC_PUBLIC
    Code:
      stack=1, locals=1, args_size=1
        start local 0 // com.mongodb.MongoCommandException this
         0: .line 84
            aload 0 /* this */
            getfield com.mongodb.MongoCommandException.response:Lorg/bson/BsonDocument;
            invokestatic com.mongodb.MongoCommandException.extractErrorMessage:(Lorg/bson/BsonDocument;)Ljava/lang/String;
            areturn
        end local 0 // com.mongodb.MongoCommandException this
      LocalVariableTable:
        Start  End  Slot  Name  Signature
            0    1     0  this  Lcom/mongodb/MongoCommandException;

  public org.bson.BsonDocument getResponse();
    descriptor: ()Lorg/bson/BsonDocument;
    flags: (0x0001) ACC_PUBLIC
    Code:
      stack=1, locals=1, args_size=1
        start local 0 // com.mongodb.MongoCommandException this
         0: .line 93
            aload 0 /* this */
            getfield com.mongodb.MongoCommandException.response:Lorg/bson/BsonDocument;
            areturn
        end local 0 // com.mongodb.MongoCommandException this
      LocalVariableTable:
        Start  End  Slot  Name  Signature
            0    1     0  this  Lcom/mongodb/MongoCommandException;

  private static java.lang.String getResponseAsJson(org.bson.BsonDocument);
    descriptor: (Lorg/bson/BsonDocument;)Ljava/lang/String;
    flags: (0x000a) ACC_PRIVATE, ACC_STATIC
    Code:
      stack=4, locals=3, args_size=1
        start local 0 // org.bson.BsonDocument commandResponse
         0: .line 97
            new java.io.StringWriter
            dup
            invokespecial java.io.StringWriter.<init>:()V
            astore 1 /* writer */
        start local 1 // java.io.StringWriter writer
         1: .line 98
            new org.bson.json.JsonWriter
            dup
            aload 1 /* writer */
            invokespecial org.bson.json.JsonWriter.<init>:(Ljava/io/Writer;)V
            astore 2 /* jsonWriter */
        start local 2 // org.bson.json.JsonWriter jsonWriter
         2: .line 99
            new org.bson.codecs.BsonDocumentCodec
            dup
            invokespecial org.bson.codecs.BsonDocumentCodec.<init>:()V
            aload 2 /* jsonWriter */
            aload 0 /* commandResponse */
            invokestatic org.bson.codecs.EncoderContext.builder:()Lorg/bson/codecs/EncoderContext$Builder;
            invokevirtual org.bson.codecs.EncoderContext$Builder.build:()Lorg/bson/codecs/EncoderContext;
            invokevirtual org.bson.codecs.BsonDocumentCodec.encode:(Lorg/bson/BsonWriter;Lorg/bson/BsonDocument;Lorg/bson/codecs/EncoderContext;)V
         3: .line 100
            aload 1 /* writer */
            invokevirtual java.io.StringWriter.toString:()Ljava/lang/String;
            areturn
        end local 2 // org.bson.json.JsonWriter jsonWriter
        end local 1 // java.io.StringWriter writer
        end local 0 // org.bson.BsonDocument commandResponse
      LocalVariableTable:
        Start  End  Slot             Name  Signature
            0    4     0  commandResponse  Lorg/bson/BsonDocument;
            1    4     1           writer  Ljava/io/StringWriter;
            2    4     2       jsonWriter  Lorg/bson/json/JsonWriter;
    MethodParameters:
                 Name  Flags
      commandResponse  final

  private static java.lang.String extractErrorCodeAndName(org.bson.BsonDocument);
    descriptor: (Lorg/bson/BsonDocument;)Ljava/lang/String;
    flags: (0x000a) ACC_PRIVATE, ACC_STATIC
    Code:
      stack=5, locals=3, args_size=1
        start local 0 // org.bson.BsonDocument response
         0: .line 104
            aload 0 /* response */
            invokestatic com.mongodb.MongoCommandException.extractErrorCode:(Lorg/bson/BsonDocument;)I
            istore 1 /* errorCode */
        start local 1 // int errorCode
         1: .line 105
            aload 0 /* response */
            invokestatic com.mongodb.MongoCommandException.extractErrorCodeName:(Lorg/bson/BsonDocument;)Ljava/lang/String;
            astore 2 /* errorCodeName */
        start local 2 // java.lang.String errorCodeName
         2: .line 106
            aload 2 /* errorCodeName */
            invokevirtual java.lang.String.isEmpty:()Z
            ifeq 4
         3: .line 107
            iload 1 /* errorCode */
            invokestatic java.lang.Integer.toString:(I)Ljava/lang/String;
            areturn
         4: .line 109
      StackMap locals: int java.lang.String
      StackMap stack:
            ldc "%d (%s)"
            iconst_2
            anewarray java.lang.Object
            dup
            iconst_0
            iload 1 /* errorCode */
            invokestatic java.lang.Integer.valueOf:(I)Ljava/lang/Integer;
            aastore
            dup
            iconst_1
            aload 2 /* errorCodeName */
            aastore
            invokestatic java.lang.String.format:(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
            areturn
        end local 2 // java.lang.String errorCodeName
        end local 1 // int errorCode
        end local 0 // org.bson.BsonDocument response
      LocalVariableTable:
        Start  End  Slot           Name  Signature
            0    5     0       response  Lorg/bson/BsonDocument;
            1    5     1      errorCode  I
            2    5     2  errorCodeName  Ljava/lang/String;
    MethodParameters:
          Name  Flags
      response  final

  private static int extractErrorCode(org.bson.BsonDocument);
    descriptor: (Lorg/bson/BsonDocument;)I
    flags: (0x000a) ACC_PRIVATE, ACC_STATIC
    Code:
      stack=5, locals=1, args_size=1
        start local 0 // org.bson.BsonDocument response
         0: .line 114
            aload 0 /* response */
            ldc "code"
            new org.bson.BsonInt32
            dup
            iconst_m1
            invokespecial org.bson.BsonInt32.<init>:(I)V
            invokevirtual org.bson.BsonDocument.getNumber:(Ljava/lang/Object;Lorg/bson/BsonNumber;)Lorg/bson/BsonNumber;
            invokevirtual org.bson.BsonNumber.intValue:()I
            ireturn
        end local 0 // org.bson.BsonDocument response
      LocalVariableTable:
        Start  End  Slot      Name  Signature
            0    1     0  response  Lorg/bson/BsonDocument;
    MethodParameters:
          Name  Flags
      response  final

  private static java.lang.String extractErrorCodeName(org.bson.BsonDocument);
    descriptor: (Lorg/bson/BsonDocument;)Ljava/lang/String;
    flags: (0x000a) ACC_PRIVATE, ACC_STATIC
    Code:
      stack=5, locals=1, args_size=1
        start local 0 // org.bson.BsonDocument response
         0: .line 118
            aload 0 /* response */
            ldc "codeName"
            new org.bson.BsonString
            dup
            ldc ""
            invokespecial org.bson.BsonString.<init>:(Ljava/lang/String;)V
            invokevirtual org.bson.BsonDocument.getString:(Ljava/lang/Object;Lorg/bson/BsonString;)Lorg/bson/BsonString;
            invokevirtual org.bson.BsonString.getValue:()Ljava/lang/String;
            areturn
        end local 0 // org.bson.BsonDocument response
      LocalVariableTable:
        Start  End  Slot      Name  Signature
            0    1     0  response  Lorg/bson/BsonDocument;
    MethodParameters:
          Name  Flags
      response  final

  private static java.lang.String extractErrorMessage(org.bson.BsonDocument);
    descriptor: (Lorg/bson/BsonDocument;)Ljava/lang/String;
    flags: (0x000a) ACC_PRIVATE, ACC_STATIC
    Code:
      stack=5, locals=2, args_size=1
        start local 0 // org.bson.BsonDocument response
         0: .line 122
            aload 0 /* response */
            ldc "errmsg"
            new org.bson.BsonString
            dup
            ldc ""
            invokespecial org.bson.BsonString.<init>:(Ljava/lang/String;)V
            invokevirtual org.bson.BsonDocument.getString:(Ljava/lang/Object;Lorg/bson/BsonString;)Lorg/bson/BsonString;
            invokevirtual org.bson.BsonString.getValue:()Ljava/lang/String;
            astore 1 /* errorMessage */
        start local 1 // java.lang.String errorMessage
         1: .line 124
            aload 1 /* errorMessage */
            ifnonnull 3
         2: .line 125
            new com.mongodb.MongoInternalException
            dup
            ldc "This value should not be null"
            invokespecial com.mongodb.MongoInternalException.<init>:(Ljava/lang/String;)V
            athrow
         3: .line 127
      StackMap locals: java.lang.String
      StackMap stack:
            aload 1 /* errorMessage */
            areturn
        end local 1 // java.lang.String errorMessage
        end local 0 // org.bson.BsonDocument response
      LocalVariableTable:
        Start  End  Slot          Name  Signature
            0    4     0      response  Lorg/bson/BsonDocument;
            1    4     1  errorMessage  Ljava/lang/String;
    MethodParameters:
          Name  Flags
      response  final
}
SourceFile: "MongoCommandException.java"
InnerClasses:
  public final Builder = org.bson.codecs.EncoderContext$Builder of org.bson.codecs.EncoderContext