Package

org.opalj

bc

Permalink

package bc

Visibility
  1. Public
  2. All

Type Members

  1. trait ClassFileElement[T] extends AnyRef

    Permalink

    Generic interface which we use to implement the type classes.

Value Members

  1. object Assembler

    Permalink

    Factory to create the binary representation (that is, an array of bytes) of a given class file.

  2. object DAandBR extends App

    Permalink

    Demonstrates how to create a "HelloWorld" class and how to interact between br and da.

    Demonstrates how to create a "HelloWorld" class and how to interact between br and da.

    public class Test {
     public static void main(String[] args) {
         System.out.println("Hello World");
     }
    }
    public class Test
    minor version: 0
    major version: 46
    flags: ACC_PUBLIC, ACC_SUPER
    Constant pool:
    #1 = Class              #2             // Test
    #2 = Utf8               Test
    #3 = Class              #4             // java/lang/Object
    #4 = Utf8               java/lang/Object
    #5 = Utf8               <init>
    #6 = Utf8               ()V
    #7 = Utf8               Code
    #8 = Methodref          #3.#9          // java/lang/Object."":()V
    #9 = NameAndType        #5:#6          // "":()V
    #10 = Utf8               LineNumberTable
    #11 = Utf8               LocalVariableTable
    #12 = Utf8               this
    #13 = Utf8               LTest;
    #14 = Utf8               main
    #15 = Utf8               ([Ljava/lang/String;)V
    #16 = Fieldref           #17.#19        // java/lang/System.out:Ljava/io/PrintStream;
    #17 = Class              #18            // java/lang/System
    #18 = Utf8               java/lang/System
    #19 = NameAndType        #20:#21        // out:Ljava/io/PrintStream;
    #20 = Utf8               out
    #21 = Utf8               Ljava/io/PrintStream;
    #22 = String             #23            // Hello World
    #23 = Utf8               Hello World
    #24 = Methodref          #25.#27        // java/io/PrintStream.println:(Ljava/lang/String;)V
    #25 = Class              #26            // java/io/PrintStream
    #26 = Utf8               java/io/PrintStream
    #27 = NameAndType        #28:#29        // println:(Ljava/lang/String;)V
    #28 = Utf8               println
    #29 = Utf8               (Ljava/lang/String;)V
    #30 = Utf8               args
    #31 = Utf8               [Ljava/lang/String;
    #32 = Utf8               SourceFile
    #33 = Utf8               Test.java
    {
    public Test();
    descriptor: ()V
    flags: ACC_PUBLIC
    Code:
    stack=1, locals=1, args_size=1
    0: aload_0
    1: invokespecial #8                  // Method java/lang/Object."":()V
    4: return
    
    public static void main(java.lang.String[]);
    descriptor: ([Ljava/lang/String;)V
    flags: ACC_PUBLIC, ACC_STATIC
    Code:
    stack=2, locals=1, args_size=1
    0: getstatic     #16                 // Field java/lang/System.out:Ljava/io/PrintStream;
    3: ldc           #22                 // String Hello World
    5: invokevirtual #24                 // Method java/io/PrintStream.println:(Ljava/lang/String;)V
    8: return
    SourceFile: "Test.java"
  3. object HelloWorldClass extends App

    Permalink

    Demonstrates how to create a "HelloWorld" class which basically has the following code:

    Demonstrates how to create a "HelloWorld" class which basically has the following code:

    public class Test {
     public static void main(String[] args) {
         System.out.println("Hello World");
     }
    }
    public class Test
    minor version: 0
    major version: 46
    flags: ACC_PUBLIC, ACC_SUPER
    Constant pool:
    #1 = Class              #2             // Test
    #2 = Utf8               Test
    #3 = Class              #4             // java/lang/Object
    #4 = Utf8               java/lang/Object
    #5 = Utf8               <init>
    #6 = Utf8               ()V
    #7 = Utf8               Code
    #8 = Methodref          #3.#9          // java/lang/Object."":()V
    #9 = NameAndType        #5:#6          // "":()V
    #10 = Utf8               LineNumberTable
    #11 = Utf8               LocalVariableTable
    #12 = Utf8               this
    #13 = Utf8               LTest;
    #14 = Utf8               main
    #15 = Utf8               ([Ljava/lang/String;)V
    #16 = Fieldref           #17.#19        // java/lang/System.out:Ljava/io/PrintStream;
    #17 = Class              #18            // java/lang/System
    #18 = Utf8               java/lang/System
    #19 = NameAndType        #20:#21        // out:Ljava/io/PrintStream;
    #20 = Utf8               out
    #21 = Utf8               Ljava/io/PrintStream;
    #22 = String             #23            // Hello World
    #23 = Utf8               Hello World
    #24 = Methodref          #25.#27        // java/io/PrintStream.println:(Ljava/lang/String;)V
    #25 = Class              #26            // java/io/PrintStream
    #26 = Utf8               java/io/PrintStream
    #27 = NameAndType        #28:#29        // println:(Ljava/lang/String;)V
    #28 = Utf8               println
    #29 = Utf8               (Ljava/lang/String;)V
    #30 = Utf8               args
    #31 = Utf8               [Ljava/lang/String;
    #32 = Utf8               SourceFile
    #33 = Utf8               Test.java
    {
    public Test();
    descriptor: ()V
    flags: ACC_PUBLIC
    Code:
    stack=1, locals=1, args_size=1
    0: aload_0
    1: invokespecial #8                  // Method java/lang/Object."":()V
    4: return
    
    public static void main(java.lang.String[]);
    descriptor: ([Ljava/lang/String;)V
    flags: ACC_PUBLIC, ACC_STATIC
    Code:
    stack=2, locals=1, args_size=1
    0: getstatic     #16                 // Field java/lang/System.out:Ljava/io/PrintStream;
    3: ldc           #22                 // String Hello World
    5: invokevirtual #24                 // Method java/io/PrintStream.println:(Ljava/lang/String;)V
    8: return
    SourceFile: "Test.java"
  4. object MethodFilter

    Permalink

    Command-line application which writes out some class files where some methods are filtered.

Ungrouped