Packages

  • package root
    Definition Classes
    root
  • package org
    Definition Classes
    root
  • package opalj
    Definition Classes
    org
  • package bi

    Implementation of a library for parsing Java bytecode and creating arbitrary representations.

    Implementation of a library for parsing Java bytecode and creating arbitrary representations.

    OPAL's primary representation of Java byte code is the org.opalj.br representation which is defined in the respective package. A second representation that represents bytecode one-by-one is found in the org.opalj.da package.

    This Package

    Common constants and type definitions used across OPAL.

    Definition Classes
    opalj
  • package bytecode

    Defines functionality commonly useful when processing Java bytecode.

    Defines functionality commonly useful when processing Java bytecode.

    Definition Classes
    opalj
  • BytecodeProcessingFailedException
p

org.opalj

bytecode

package bytecode

Defines functionality commonly useful when processing Java bytecode.

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. bytecode
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Type Members

  1. case class BytecodeProcessingFailedException(message: String) extends RuntimeException with Product with Serializable

    Indicates that the processing of a class file failed.

    Indicates that the processing of a class file failed. The reason is either a bug in the framework or in the class file.

    Note

    The Eclipse Luna Java compiler does not generate valid class files in a few cases where type annotations are used in combination with try-with-resources statements.

    ,

    The Scala compiler - at least up to version 2.12.5 - sometimes generates invalid type signatures in the combination with parameterized value types.

  2. final type PC = Int

    The program counter of an instruction.

    The program counter of an instruction. A value in the range [0..65535].

Value Members

  1. lazy val JRELibraryFolder: File

    Returns the most likely position of the JRE's library folder.

    Returns the most likely position of the JRE's library folder. (I.e., the location in which the rt.jar file and the other jar files belonging to the Java runtime environment can be found). If the rt.jar cannot be found an exception is raised.

  2. def JVMInstructions: List[(Int, String)]

    The list of all JVM instructions in the format: "<OPCODE><MNEMONIC>NewLine".

  3. def JVMOpcodes: BitSet

    The set of all valid/used opcodes.

  4. lazy val RTJar: File

    Returns the most likely position of the JAR/JMod that contains Java's main classes.

  5. def abbreviateType(definingTypeFQN: String, memberTypeFQN: String, pkgSeparatorChar: Int = '.'): String

    Abbreviates the given memberTypeFQN by abbreviating the common packages (except of the last shared package) of both fully qualified type names using '…'.

    Abbreviates the given memberTypeFQN by abbreviating the common packages (except of the last shared package) of both fully qualified type names using '…'.

    pkgSeparatorChar

    If the given fully qualified type names are using Java notation (i.e., packages are separated using '.') then the parameter should be '.', which is the default, otherwise the parameter should be '/'.

    Example:
    1. scala> org.opalj.abbreviateType("a.b.T","a.T") // <= no abbrev.
      res: String = a.T
      
      scala> org.opalj.abbreviateType("a.b.T","a.b.T")
      res: String = …b.T
      
      scala> org.opalj.abbreviateType("a.b.c.T","a.b.c.T.X")
      res: String = …c.T.X
  6. def commonPackage(fqnA: String, fqnB: String, pkgSeparatorChar: Int = '.'): Option[String]

    Returns the package definitions shared by both fully qualified type names.

    Returns the package definitions shared by both fully qualified type names. If both types do not define a common package None is returned.

    pkgSeparatorChar

    If the given fully qualified type names are using Java notation (i.e., packages are separated using '.') then the parameter should be '.', which is the default, otherwise the parameter should be '/'.

    Example:
    1. scala> org.opalj.commonPackage("a.b.T","a.c.T")
      res: Option[String] = Some(a.)
      
      scala> org.opalj.commonPackage("a.b.T","a.T")
      res: Option[String] = Some(a.)
      
      scala> org.opalj.commonPackage("a.b.T","a.b.T")
      res: Option[String] = Some(a.b.)
      
      scala> org.opalj.commonPackage("c.b.T","a.T")
      res: Option[String] = None
      
      scala> org.opalj.commonPackage("a.b.T","d.c.T")
      res: Option[String] = None

Inherited from AnyRef

Inherited from Any

Ungrouped