class jdk.internal.jshell.tool.JShellTool$ReplayableHistory
  minor version: 0
  major version: 59
  flags: flags: (0x0020) ACC_SUPER
  this_class: jdk.internal.jshell.tool.JShellTool$ReplayableHistory
  super_class: java.lang.Object
{
  private java.util.List<java.lang.String> hist;
    descriptor: Ljava/util/List;
    flags: (0x0002) ACC_PRIVATE
    Signature: Ljava/util/List<Ljava/lang/String;>;

  private int lastSaved;
    descriptor: I
    flags: (0x0002) ACC_PRIVATE

  private void <init>(java.util.List<java.lang.String>);
    descriptor: (Ljava/util/List;)V
    flags: (0x0002) ACC_PRIVATE
    Code:
      stack=2, locals=2, args_size=2
        start local 0 // jdk.internal.jshell.tool.JShellTool$ReplayableHistory this
        start local 1 // java.util.List hist
         0: .line 638
            aload 0 /* this */
            invokespecial java.lang.Object.<init>:()V
         1: .line 639
            aload 0 /* this */
            aload 1 /* hist */
            putfield jdk.internal.jshell.tool.JShellTool$ReplayableHistory.hist:Ljava/util/List;
         2: .line 640
            aload 0 /* this */
            iconst_0
            putfield jdk.internal.jshell.tool.JShellTool$ReplayableHistory.lastSaved:I
         3: .line 641
            return
        end local 1 // java.util.List hist
        end local 0 // jdk.internal.jshell.tool.JShellTool$ReplayableHistory this
      LocalVariableTable:
        Start  End  Slot  Name  Signature
            0    4     0  this  Ljdk/internal/jshell/tool/JShellTool$ReplayableHistory;
            0    4     1  hist  Ljava/util/List<Ljava/lang/String;>;
    Signature: (Ljava/util/List<Ljava/lang/String;>;)V
    MethodParameters:
      Name  Flags
      hist  

  static jdk.internal.jshell.tool.JShellTool$ReplayableHistory emptyHistory();
    descriptor: ()Ljdk/internal/jshell/tool/JShellTool$ReplayableHistory;
    flags: (0x0008) ACC_STATIC
    Code:
      stack=4, locals=0, args_size=0
         0: .line 645
            new jdk.internal.jshell.tool.JShellTool$ReplayableHistory
            dup
            new java.util.ArrayList
            dup
            invokespecial java.util.ArrayList.<init>:()V
            invokespecial jdk.internal.jshell.tool.JShellTool$ReplayableHistory.<init>:(Ljava/util/List;)V
            areturn
      LocalVariableTable:
        Start  End  Slot  Name  Signature

  static jdk.internal.jshell.tool.JShellTool$ReplayableHistory fromPrevious(jdk.internal.jshell.tool.PersistentStorage);
    descriptor: (Ljdk/internal/jshell/tool/PersistentStorage;)Ljdk/internal/jshell/tool/JShellTool$ReplayableHistory;
    flags: (0x0008) ACC_STATIC
    Code:
      stack=4, locals=2, args_size=1
        start local 0 // jdk.internal.jshell.tool.PersistentStorage prefs
         0: .line 651
            aload 0 /* prefs */
            ldc "REPLAY_RESTORE"
            invokeinterface jdk.internal.jshell.tool.PersistentStorage.get:(Ljava/lang/String;)Ljava/lang/String;
            astore 1 /* prevReplay */
        start local 1 // java.lang.String prevReplay
         1: .line 652
            aload 1 /* prevReplay */
            ifnonnull 3
         2: .line 653
            aconst_null
            areturn
         3: .line 655
      StackMap locals: java.lang.String
      StackMap stack:
            new jdk.internal.jshell.tool.JShellTool$ReplayableHistory
            dup
            aload 1 /* prevReplay */
            ldc "\u241E"
            invokevirtual java.lang.String.split:(Ljava/lang/String;)[Ljava/lang/String;
            invokestatic java.util.Arrays.asList:([Ljava/lang/Object;)Ljava/util/List;
            invokespecial jdk.internal.jshell.tool.JShellTool$ReplayableHistory.<init>:(Ljava/util/List;)V
            areturn
        end local 1 // java.lang.String prevReplay
        end local 0 // jdk.internal.jshell.tool.PersistentStorage prefs
      LocalVariableTable:
        Start  End  Slot        Name  Signature
            0    4     0       prefs  Ljdk/internal/jshell/tool/PersistentStorage;
            1    4     1  prevReplay  Ljava/lang/String;
    MethodParameters:
       Name  Flags
      prefs  

  void storeHistory(jdk.internal.jshell.tool.PersistentStorage);
    descriptor: (Ljdk/internal/jshell/tool/PersistentStorage;)V
    flags: (0x0000) 
    Code:
      stack=4, locals=6, args_size=2
        start local 0 // jdk.internal.jshell.tool.JShellTool$ReplayableHistory this
        start local 1 // jdk.internal.jshell.tool.PersistentStorage prefs
         0: .line 662
            aload 0 /* this */
            getfield jdk.internal.jshell.tool.JShellTool$ReplayableHistory.hist:Ljava/util/List;
            invokeinterface java.util.List.size:()I
            aload 0 /* this */
            getfield jdk.internal.jshell.tool.JShellTool$ReplayableHistory.lastSaved:I
            if_icmple 12
         1: .line 665
            ldc "\u241E"
            invokevirtual java.lang.String.length:()I
            istore 2 /* sepLen */
        start local 2 // int sepLen
         2: .line 666
            iconst_0
            istore 3 /* length */
        start local 3 // int length
         3: .line 667
            aload 0 /* this */
            getfield jdk.internal.jshell.tool.JShellTool$ReplayableHistory.hist:Ljava/util/List;
            invokeinterface java.util.List.size:()I
            istore 4 /* first */
        start local 4 // int first
         4: .line 668
            goto 6
         5: .line 669
      StackMap locals: int int int
      StackMap stack:
            iload 3 /* length */
            aload 0 /* this */
            getfield jdk.internal.jshell.tool.JShellTool$ReplayableHistory.hist:Ljava/util/List;
            iload 4 /* first */
            invokeinterface java.util.List.get:(I)Ljava/lang/Object;
            checkcast java.lang.String
            invokevirtual java.lang.String.length:()I
            iload 2 /* sepLen */
            iadd
            iadd
            istore 3 /* length */
         6: .line 668
      StackMap locals:
      StackMap stack:
            iload 3 /* length */
            sipush 8192
            if_icmpge 7
            iinc 4 /* first */ -1
            iload 4 /* first */
            ifge 5
         7: .line 671
      StackMap locals:
      StackMap stack:
            iload 4 /* first */
            iflt 9
         8: .line 672
            aload 0 /* this */
            aload 0 /* this */
            getfield jdk.internal.jshell.tool.JShellTool$ReplayableHistory.hist:Ljava/util/List;
            iload 4 /* first */
            iconst_1
            iadd
            aload 0 /* this */
            getfield jdk.internal.jshell.tool.JShellTool$ReplayableHistory.hist:Ljava/util/List;
            invokeinterface java.util.List.size:()I
            invokeinterface java.util.List.subList:(II)Ljava/util/List;
            putfield jdk.internal.jshell.tool.JShellTool$ReplayableHistory.hist:Ljava/util/List;
         9: .line 674
      StackMap locals:
      StackMap stack:
            ldc "\u241E"
            aload 0 /* this */
            getfield jdk.internal.jshell.tool.JShellTool$ReplayableHistory.hist:Ljava/util/List;
            invokestatic java.lang.String.join:(Ljava/lang/CharSequence;Ljava/lang/Iterable;)Ljava/lang/String;
            astore 5 /* shist */
        start local 5 // java.lang.String shist
        10: .line 675
            aload 1 /* prefs */
            ldc "REPLAY_RESTORE"
            aload 5 /* shist */
            invokeinterface jdk.internal.jshell.tool.PersistentStorage.put:(Ljava/lang/String;Ljava/lang/String;)V
        11: .line 676
            aload 0 /* this */
            invokevirtual jdk.internal.jshell.tool.JShellTool$ReplayableHistory.markSaved:()V
        end local 5 // java.lang.String shist
        end local 4 // int first
        end local 3 // int length
        end local 2 // int sepLen
        12: .line 678
      StackMap locals:
      StackMap stack:
            aload 1 /* prefs */
            invokeinterface jdk.internal.jshell.tool.PersistentStorage.flush:()V
        13: .line 679
            return
        end local 1 // jdk.internal.jshell.tool.PersistentStorage prefs
        end local 0 // jdk.internal.jshell.tool.JShellTool$ReplayableHistory this
      LocalVariableTable:
        Start  End  Slot    Name  Signature
            0   14     0    this  Ljdk/internal/jshell/tool/JShellTool$ReplayableHistory;
            0   14     1   prefs  Ljdk/internal/jshell/tool/PersistentStorage;
            2   12     2  sepLen  I
            3   12     3  length  I
            4   12     4   first  I
           10   12     5   shist  Ljava/lang/String;
    MethodParameters:
       Name  Flags
      prefs  

  void add(java.lang.String);
    descriptor: (Ljava/lang/String;)V
    flags: (0x0000) 
    Code:
      stack=2, locals=2, args_size=2
        start local 0 // jdk.internal.jshell.tool.JShellTool$ReplayableHistory this
        start local 1 // java.lang.String s
         0: .line 683
            aload 0 /* this */
            getfield jdk.internal.jshell.tool.JShellTool$ReplayableHistory.hist:Ljava/util/List;
            aload 1 /* s */
            invokeinterface java.util.List.add:(Ljava/lang/Object;)Z
            pop
         1: .line 684
            return
        end local 1 // java.lang.String s
        end local 0 // jdk.internal.jshell.tool.JShellTool$ReplayableHistory this
      LocalVariableTable:
        Start  End  Slot  Name  Signature
            0    2     0  this  Ljdk/internal/jshell/tool/JShellTool$ReplayableHistory;
            0    2     1     s  Ljava/lang/String;
    MethodParameters:
      Name  Flags
      s     

  java.lang.Iterable<java.lang.String> iterable();
    descriptor: ()Ljava/lang/Iterable;
    flags: (0x0000) 
    Code:
      stack=1, locals=1, args_size=1
        start local 0 // jdk.internal.jshell.tool.JShellTool$ReplayableHistory this
         0: .line 688
            aload 0 /* this */
            getfield jdk.internal.jshell.tool.JShellTool$ReplayableHistory.hist:Ljava/util/List;
            areturn
        end local 0 // jdk.internal.jshell.tool.JShellTool$ReplayableHistory this
      LocalVariableTable:
        Start  End  Slot  Name  Signature
            0    1     0  this  Ljdk/internal/jshell/tool/JShellTool$ReplayableHistory;
    Signature: ()Ljava/lang/Iterable<Ljava/lang/String;>;

  void markSaved();
    descriptor: ()V
    flags: (0x0000) 
    Code:
      stack=2, locals=1, args_size=1
        start local 0 // jdk.internal.jshell.tool.JShellTool$ReplayableHistory this
         0: .line 693
            aload 0 /* this */
            aload 0 /* this */
            getfield jdk.internal.jshell.tool.JShellTool$ReplayableHistory.hist:Ljava/util/List;
            invokeinterface java.util.List.size:()I
            putfield jdk.internal.jshell.tool.JShellTool$ReplayableHistory.lastSaved:I
         1: .line 694
            return
        end local 0 // jdk.internal.jshell.tool.JShellTool$ReplayableHistory this
      LocalVariableTable:
        Start  End  Slot  Name  Signature
            0    2     0  this  Ljdk/internal/jshell/tool/JShellTool$ReplayableHistory;
}
SourceFile: "JShellTool.java"
NestHost: jdk.internal.jshell.tool.JShellTool
InnerClasses:
  private ReplayableHistory = jdk.internal.jshell.tool.JShellTool$ReplayableHistory of jdk.internal.jshell.tool.JShellTool