class jdk.tools.jmod.JmodOutputStream extends java.io.OutputStream implements java.lang.AutoCloseable
minor version: 0
major version: 59
flags: flags: (0x0020) ACC_SUPER
this_class: jdk.tools.jmod.JmodOutputStream
super_class: java.io.OutputStream
{
private final java.util.Map<jdk.internal.jmod.JmodFile$Section, java.util.Set<java.lang.String>> entries;
descriptor: Ljava/util/Map;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
Signature: Ljava/util/Map<Ljdk/internal/jmod/JmodFile$Section;Ljava/util/Set<Ljava/lang/String;>;>;
private final java.util.zip.ZipOutputStream zos;
descriptor: Ljava/util/zip/ZipOutputStream;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
static jdk.tools.jmod.JmodOutputStream newOutputStream(java.nio.file.Path);
descriptor: (Ljava/nio/file/Path;)Ljdk/tools/jmod/JmodOutputStream;
flags: (0x0008) ACC_STATIC
Code:
stack=3, locals=3, args_size=1
start local 0 0: aload 0
iconst_0
anewarray java.nio.file.OpenOption
invokestatic java.nio.file.Files.newOutputStream:(Ljava/nio/file/Path;[Ljava/nio/file/OpenOption;)Ljava/io/OutputStream;
astore 1
start local 1 1: new java.io.BufferedOutputStream
dup
aload 1
invokespecial java.io.BufferedOutputStream.<init>:(Ljava/io/OutputStream;)V
astore 2
start local 2 2: new jdk.tools.jmod.JmodOutputStream
dup
aload 2
invokespecial jdk.tools.jmod.JmodOutputStream.<init>:(Ljava/io/OutputStream;)V
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 file Ljava/nio/file/Path;
1 3 1 out Ljava/io/OutputStream;
2 3 2 bos Ljava/io/BufferedOutputStream;
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
file
private void <init>(java.io.OutputStream);
descriptor: (Ljava/io/OutputStream;)V
flags: (0x0002) ACC_PRIVATE
Code:
stack=4, locals=3, args_size=2
start local 0 start local 1 0: aload 0
invokespecial java.io.OutputStream.<init>:()V
1: aload 0
new java.util.HashMap
dup
invokespecial java.util.HashMap.<init>:()V
putfield jdk.tools.jmod.JmodOutputStream.entries:Ljava/util/Map;
2: aload 0
new java.util.zip.ZipOutputStream
dup
aload 1
invokespecial java.util.zip.ZipOutputStream.<init>:(Ljava/io/OutputStream;)V
putfield jdk.tools.jmod.JmodOutputStream.zos:Ljava/util/zip/ZipOutputStream;
3: aload 1
invokestatic jdk.internal.jmod.JmodFile.writeMagicNumber:(Ljava/io/OutputStream;)V
4: goto 7
StackMap locals: jdk.tools.jmod.JmodOutputStream java.io.OutputStream
StackMap stack: java.io.IOException
5: astore 2
start local 2 6: new java.io.UncheckedIOException
dup
aload 2
invokespecial java.io.UncheckedIOException.<init>:(Ljava/io/IOException;)V
athrow
end local 2 7: StackMap locals:
StackMap stack:
return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 8 0 this Ljdk/tools/jmod/JmodOutputStream;
0 8 1 out Ljava/io/OutputStream;
6 7 2 e Ljava/io/IOException;
Exception table:
from to target type
3 4 5 Class java.io.IOException
MethodParameters:
Name Flags
out
public void writeEntry(java.io.InputStream, jdk.internal.jmod.JmodFile$Section, java.lang.String);
descriptor: (Ljava/io/InputStream;Ljdk/internal/jmod/JmodFile$Section;Ljava/lang/String;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=3, locals=5, args_size=4
start local 0 start local 1 start local 2 start local 3 0: aload 0
aload 2
aload 3
invokevirtual jdk.tools.jmod.JmodOutputStream.newEntry:(Ljdk/internal/jmod/JmodFile$Section;Ljava/lang/String;)Ljava/util/zip/ZipEntry;
astore 4
start local 4 1: aload 0
getfield jdk.tools.jmod.JmodOutputStream.zos:Ljava/util/zip/ZipOutputStream;
aload 4
invokevirtual java.util.zip.ZipOutputStream.putNextEntry:(Ljava/util/zip/ZipEntry;)V
2: aload 1
aload 0
getfield jdk.tools.jmod.JmodOutputStream.zos:Ljava/util/zip/ZipOutputStream;
invokevirtual java.io.InputStream.transferTo:(Ljava/io/OutputStream;)J
pop2
3: aload 0
getfield jdk.tools.jmod.JmodOutputStream.zos:Ljava/util/zip/ZipOutputStream;
invokevirtual java.util.zip.ZipOutputStream.closeEntry:()V
4: return
end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Ljdk/tools/jmod/JmodOutputStream;
0 5 1 in Ljava/io/InputStream;
0 5 2 section Ljdk/internal/jmod/JmodFile$Section;
0 5 3 name Ljava/lang/String;
1 5 4 ze Ljava/util/zip/ZipEntry;
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
in
section
name
public void writeEntry(byte[], jdk.internal.jmod.JmodFile$Section, java.lang.String);
descriptor: ([BLjdk/internal/jmod/JmodFile$Section;Ljava/lang/String;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=3, locals=5, args_size=4
start local 0 start local 1 start local 2 start local 3 0: aload 0
aload 2
aload 3
invokevirtual jdk.tools.jmod.JmodOutputStream.newEntry:(Ljdk/internal/jmod/JmodFile$Section;Ljava/lang/String;)Ljava/util/zip/ZipEntry;
astore 4
start local 4 1: aload 0
getfield jdk.tools.jmod.JmodOutputStream.zos:Ljava/util/zip/ZipOutputStream;
aload 4
invokevirtual java.util.zip.ZipOutputStream.putNextEntry:(Ljava/util/zip/ZipEntry;)V
2: aload 0
getfield jdk.tools.jmod.JmodOutputStream.zos:Ljava/util/zip/ZipOutputStream;
aload 1
invokevirtual java.util.zip.ZipOutputStream.write:([B)V
3: aload 0
getfield jdk.tools.jmod.JmodOutputStream.zos:Ljava/util/zip/ZipOutputStream;
invokevirtual java.util.zip.ZipOutputStream.closeEntry:()V
4: return
end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Ljdk/tools/jmod/JmodOutputStream;
0 5 1 bytes [B
0 5 2 section Ljdk/internal/jmod/JmodFile$Section;
0 5 3 path Ljava/lang/String;
1 5 4 ze Ljava/util/zip/ZipEntry;
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
bytes
section
path
public void writeEntry(java.io.InputStream, jdk.internal.jmod.JmodFile$Entry);
descriptor: (Ljava/io/InputStream;Ljdk/internal/jmod/JmodFile$Entry;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=3, locals=5, args_size=3
start local 0 start local 1 start local 2 0: aload 2
invokevirtual jdk.internal.jmod.JmodFile$Entry.zipEntry:()Ljava/util/zip/ZipEntry;
astore 3
start local 3 1: new java.util.zip.ZipEntry
dup
aload 3
invokevirtual java.util.zip.ZipEntry.getName:()Ljava/lang/String;
invokespecial java.util.zip.ZipEntry.<init>:(Ljava/lang/String;)V
astore 4
start local 4 2: aload 4
aload 3
invokevirtual java.util.zip.ZipEntry.getMethod:()I
invokevirtual java.util.zip.ZipEntry.setMethod:(I)V
3: aload 4
aload 3
invokevirtual java.util.zip.ZipEntry.getTime:()J
invokevirtual java.util.zip.ZipEntry.setTime:(J)V
4: aload 4
aload 3
invokevirtual java.util.zip.ZipEntry.getComment:()Ljava/lang/String;
invokevirtual java.util.zip.ZipEntry.setComment:(Ljava/lang/String;)V
5: aload 4
aload 3
invokevirtual java.util.zip.ZipEntry.getExtra:()[B
invokevirtual java.util.zip.ZipEntry.setExtra:([B)V
6: aload 3
invokevirtual java.util.zip.ZipEntry.getMethod:()I
ifne 9
7: aload 4
aload 3
invokevirtual java.util.zip.ZipEntry.getSize:()J
invokevirtual java.util.zip.ZipEntry.setSize:(J)V
8: aload 4
aload 3
invokevirtual java.util.zip.ZipEntry.getCrc:()J
invokevirtual java.util.zip.ZipEntry.setCrc:(J)V
9: StackMap locals: java.util.zip.ZipEntry java.util.zip.ZipEntry
StackMap stack:
aload 0
getfield jdk.tools.jmod.JmodOutputStream.zos:Ljava/util/zip/ZipOutputStream;
aload 4
invokevirtual java.util.zip.ZipOutputStream.putNextEntry:(Ljava/util/zip/ZipEntry;)V
10: aload 0
getfield jdk.tools.jmod.JmodOutputStream.zos:Ljava/util/zip/ZipOutputStream;
aload 1
invokevirtual java.io.InputStream.readAllBytes:()[B
invokevirtual java.util.zip.ZipOutputStream.write:([B)V
11: aload 0
getfield jdk.tools.jmod.JmodOutputStream.zos:Ljava/util/zip/ZipOutputStream;
invokevirtual java.util.zip.ZipOutputStream.closeEntry:()V
12: return
end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 13 0 this Ljdk/tools/jmod/JmodOutputStream;
0 13 1 in Ljava/io/InputStream;
0 13 2 e Ljdk/internal/jmod/JmodFile$Entry;
1 13 3 e1 Ljava/util/zip/ZipEntry;
2 13 4 e2 Ljava/util/zip/ZipEntry;
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
in
e
private java.util.zip.ZipEntry newEntry(jdk.internal.jmod.JmodFile$Section, java.lang.String);
descriptor: (Ljdk/internal/jmod/JmodFile$Section;Ljava/lang/String;)Ljava/util/zip/ZipEntry;
flags: (0x0002) ACC_PRIVATE
Code:
stack=5, locals=5, args_size=3
start local 0 start local 1 start local 2 0: aload 0
aload 1
aload 2
invokevirtual jdk.tools.jmod.JmodOutputStream.contains:(Ljdk/internal/jmod/JmodFile$Section;Ljava/lang/String;)Z
ifeq 2
1: new java.io.IOException
dup
new java.lang.StringBuilder
dup
ldc "duplicate entry: "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
aload 2
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
ldc " in section "
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
aload 1
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/Object;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
invokespecial java.io.IOException.<init>:(Ljava/lang/String;)V
athrow
2: StackMap locals:
StackMap stack:
aload 1
invokevirtual jdk.internal.jmod.JmodFile$Section.jmodDir:()Ljava/lang/String;
astore 3
start local 3 3: aload 3
iconst_1
anewarray java.lang.String
dup
iconst_0
aload 2
aastore
invokestatic java.nio.file.Paths.get:(Ljava/lang/String;[Ljava/lang/String;)Ljava/nio/file/Path;
invokeinterface java.nio.file.Path.toString:()Ljava/lang/String;
4: getstatic java.io.File.separatorChar:C
bipush 47
invokevirtual java.lang.String.replace:(CC)Ljava/lang/String;
5: astore 4
start local 4 6: aload 0
getfield jdk.tools.jmod.JmodOutputStream.entries:Ljava/util/Map;
aload 1
invokeinterface java.util.Map.get:(Ljava/lang/Object;)Ljava/lang/Object;
checkcast java.util.Set
aload 2
invokeinterface java.util.Set.add:(Ljava/lang/Object;)Z
pop
7: new java.util.zip.ZipEntry
dup
aload 4
invokespecial java.util.zip.ZipEntry.<init>:(Ljava/lang/String;)V
areturn
end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 8 0 this Ljdk/tools/jmod/JmodOutputStream;
0 8 1 section Ljdk/internal/jmod/JmodFile$Section;
0 8 2 path Ljava/lang/String;
3 8 3 prefix Ljava/lang/String;
6 8 4 name Ljava/lang/String;
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
section
path
public boolean contains(jdk.internal.jmod.JmodFile$Section, java.lang.String);
descriptor: (Ljdk/internal/jmod/JmodFile$Section;Ljava/lang/String;)Z
flags: (0x0001) ACC_PUBLIC
Code:
stack=3, locals=4, args_size=3
start local 0 start local 1 start local 2 0: aload 0
getfield jdk.tools.jmod.JmodOutputStream.entries:Ljava/util/Map;
aload 1
invokedynamic apply()Ljava/util/function/Function;
Bootstrap: invokestatic java.lang.invoke.LambdaMetafactory.metafactory:(Ljava/lang/invoke/MethodHandles$Lookup;Ljava/lang/String;Ljava/lang/invoke/MethodType;Ljava/lang/invoke/MethodType;Ljava/lang/invoke/MethodHandle;Ljava/lang/invoke/MethodType;)Ljava/lang/invoke/CallSite;
Method arguments:
(Ljava/lang/Object;)Ljava/lang/Object;
jdk/tools/jmod/JmodOutputStream.lambda$0(Ljdk/internal/jmod/JmodFile$Section;)Ljava/util/Set; (6)
(Ljdk/internal/jmod/JmodFile$Section;)Ljava/util/Set;
invokeinterface java.util.Map.computeIfAbsent:(Ljava/lang/Object;Ljava/util/function/Function;)Ljava/lang/Object;
checkcast java.util.Set
astore 3
start local 3 1: aload 3
aload 2
invokeinterface java.util.Set.contains:(Ljava/lang/Object;)Z
ireturn
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Ljdk/tools/jmod/JmodOutputStream;
0 2 1 section Ljdk/internal/jmod/JmodFile$Section;
0 2 2 path Ljava/lang/String;
1 2 3 set Ljava/util/Set<Ljava/lang/String;>;
MethodParameters:
Name Flags
section
path
public void write(int);
descriptor: (I)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
getfield jdk.tools.jmod.JmodOutputStream.zos:Ljava/util/zip/ZipOutputStream;
iload 1
invokevirtual java.util.zip.ZipOutputStream.write:(I)V
1: return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Ljdk/tools/jmod/JmodOutputStream;
0 2 1 b I
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
b
public void close();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield jdk.tools.jmod.JmodOutputStream.zos:Ljava/util/zip/ZipOutputStream;
invokevirtual java.util.zip.ZipOutputStream.close:()V
1: return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Ljdk/tools/jmod/JmodOutputStream;
Exceptions:
throws java.io.IOException
private static java.util.Set lambda$0(jdk.internal.jmod.JmodFile$Section);
descriptor: (Ljdk/internal/jmod/JmodFile$Section;)Ljava/util/Set;
flags: (0x100a) ACC_PRIVATE, ACC_STATIC, ACC_SYNTHETIC
Code:
stack=2, locals=1, args_size=1
start local 0 0: new java.util.HashSet
dup
invokespecial java.util.HashSet.<init>:()V
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 k Ljdk/internal/jmod/JmodFile$Section;
}
SourceFile: "JmodOutputStream.java"
InnerClasses:
public final Lookup = java.lang.invoke.MethodHandles$Lookup of java.lang.invoke.MethodHandles
public Entry = jdk.internal.jmod.JmodFile$Entry of jdk.internal.jmod.JmodFile
public final Section = jdk.internal.jmod.JmodFile$Section of jdk.internal.jmod.JmodFile