Packages

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

    OPAL is a Scala-based framework for the static analysis, manipulation and creation of Java bytecode.

    OPAL is a Scala-based framework for the static analysis, manipulation and creation of Java bytecode. OPAL is designed with performance, scalability and adaptability in mind.

    Its main components are:

    • a library (Common) which provides generally useful data-structures and algorithms for static analyses.
    • a framework for implementing lattice based static analyses (Static Analysis Infrastructure)
    • a framework for parsing Java bytecode (Bytecode Infrastructure) that can be used to create arbitrary representations.
    • a library to create a one-to-one in-memory representation of Java bytecode (Bytecode Disassembler).
    • a library to create a representation of Java bytecode that facilitates writing simple static analyses (Bytecode Representation - org.opalj.br).
    • a scalable, easily customizable framework for the abstract interpretation of Java bytecode (Abstract Interpretation Framework - org.opalj.ai).
    • a library to extract dependencies between code elements and to facilitate checking architecture definitions.
    • a library for the lightweight manipulation and creation of Java bytecode (Bytecode Assembler).

    General Design Decisions

    Thread Safety

    Unless explicitly noted, OPAL is thread safe. I.e., the classes defined by OPAL can be considered to be thread safe unless otherwise stated. (For example, it is possible to read and process class files concurrently without explicit synchronization on the client side.)

    No null Values

    Unless explicitly noted, OPAL does not null values I.e., fields that are accessible will never contain null values and methods will never return null. If a method accepts null as a value for a parameter or returns a null value it is always explicitly documented. In general, the behavior of methods that are passed null values is undefined unless explicitly documented.

    No Typecasts for Collections

    For efficiency reasons, OPAL sometimes uses mutable data-structures internally. After construction time, these data-structures are generally represented using their generic interfaces (e.g., scala.collection.{Set,Map}). However, a downcast (e.g., to add/remove elements) is always forbidden as it would effectively prevent thread-safety.

    Assertions

    OPAL makes heavy use of Scala's Assertion Facility to facilitate writing correct code. Hence, for production builds (after thorough testing(!)) it is highly recommend to build OPAL again using -Xdisable-assertions.

    Definition Classes
    org
  • package ai

    Implementation of an abstract interpretation (ai) framework – also referred to as OPAL.

    Implementation of an abstract interpretation (ai) framework – also referred to as OPAL.

    Please note that OPAL/the abstract interpreter just refers to the classes and traits defined in this package (ai). The classes and traits defined in the sub-packages (in particular in domain) are not considered to be part of the core of OPAL/the abstract interpreter.

    Definition Classes
    opalj
    Note

    This framework assumes that the analyzed bytecode is valid; i.e., the JVM's bytecode verifier would be able to verify the code. Furthermore, load-time errors (e.g., LinkageErrors) are – by default – completely ignored to facilitate the analysis of parts of a project. In general, if the presented bytecode is not valid, the result is undefined (i.e., OPAL may report meaningless results, crash or run indefinitely).

    See also

    org.opalj.ai.AI - Implements the abstract interpreter that processes a methods code and uses an analysis-specific domain to perform the abstract computations.

    org.opalj.ai.Domain - The core interface between the abstract interpretation framework and the abstract domain that is responsible for performing the abstract computations.

  • package av
    Definition Classes
    opalj
  • package ba

    Implementation of an eDSL for creating Java bytecode.

    Implementation of an eDSL for creating Java bytecode. The eDSL is designed to facilitate the creation of correct class files; i.e., whenever possible it tries to fill wholes. For example, when an interface is specified the library automatically ensures that the super class type is (initially) set to java.lang.Object as required by the JVM specification.

    This package in particular provides functionality to convert org.opalj.br classes to org.opalj.da classes.

    Definition Classes
    opalj
  • package bc
    Definition Classes
    opalj
  • 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 br

    In this representation of Java bytecode references to a Java class file's constant pool and to attributes are replaced by direct references to the corresponding constant pool entries.

    In this representation of Java bytecode references to a Java class file's constant pool and to attributes are replaced by direct references to the corresponding constant pool entries. This facilitates developing analyses and fosters comprehension.

    Based on the fact that indirect references to constant pool entries are resolved and replaced by direct references this representation is called the resolved representation.

    This representation of Java bytecode is considered as OPAL's standard representation for writing Scala based analyses. This representation is engineered such that it facilitates writing analyses that use pattern matching.

    Definition Classes
    opalj
  • package bytecode

    Defines functionality commonly useful when processing Java bytecode.

    Defines functionality commonly useful when processing Java bytecode.

    Definition Classes
    opalj
  • package collection

    OPAL's collection library is primarily designed with high performance in mind.

    Design Goals

    OPAL's collection library is primarily designed with high performance in mind. I.e., all methods provided by the collection library are reasonably optimized. However, providing a very large number of methods is a non-goal. Overall, OPAL's collection library provides:

    • collection classes that are manually specialized for primitive data-types.
    • collection classes that are optimized for particularly small collections of values.
    • collection classes that target special use cases such as using a collection as a workset/worklist.
    • collection classes that offer special methods that minimize the number of steps when compared to general purpose methods.

    Integration With Scala's Collection Library

    Hence, OPAL's collection library complements Scala's default collection library and is not intended to replace it. Integration with Scala's collection library is primarily provided by means of iterators (OPAL's Iterators inherit from Scala's Iterators). Furthermore the companion object of each of OPAL's collection classes generally provides factory methods that facilitate the conversion from Scala collection classes to OPAL collection classes.

    Status

    The collection library is growing. Nevertheless, the existing classes are production ready.

    Definition Classes
    opalj
  • package concurrent

    Common constants, factory methods and objects used throughout OPAL when performing concurrent computations.

    Common constants, factory methods and objects used throughout OPAL when performing concurrent computations.

    Definition Classes
    opalj
  • package constraints

    Defines helper values and methods related to modeling constraints.

    Defines helper values and methods related to modeling constraints.

    Definition Classes
    opalj
  • package control

    Defines common control abstractions.

    Defines common control abstractions.

    Definition Classes
    opalj
  • package da

    Defines convenience methods related to representing certain class file elements.

    Defines convenience methods related to representing certain class file elements.

    Definition Classes
    opalj
  • package de

    Functionality to extract dependencies between class files.

    Functionality to extract dependencies between class files.

    Definition Classes
    opalj
  • package fpcf

    The fixpoint computations framework (fpcf) is a general framework to perform fixpoint computations of properties ordered by a lattice.

    The fixpoint computations framework (fpcf) is a general framework to perform fixpoint computations of properties ordered by a lattice. The framework in particular supports the development of static analyses.

    In this case, the fixpoint computations/static analyses are generally operating on the code and need to be executed until the computations have reached their (implicit) fixpoint. The fixpoint framework explicitly supports resolving cyclic dependencies/computations. A prime use case of the fixpoint framework are all those analyses that may interact with the results of other analyses.

    For example, an analysis that analyzes all field write accesses to determine if we can refine a field's type (for the purpose of the analysis) can (reuse) the information about the return types of methods, which however may depend on the refined field types.

    The framework is generic enough to facilitate the implementation of anytime algorithms.

    Definition Classes
    opalj
    Note

    This framework assumes that all data-structures (e.g., dependee lists and properties) that are passed to the framework are effectively immutable! (Effectively immutable means that a data structure is never updated after it was passed to the framework.)

    ,

    The dependency relation is as follows: “A depends on B” === “A is the depender, B is the dependee”. === “B is depended on by A”

    ,

    The very core of the framework is described in: Lattice Based Modularization of Static Analyses

  • package graphs

    This package defines graph algorithms as well as factory methods to describe and compute graphs and trees.

    This package defines graph algorithms as well as factory methods to describe and compute graphs and trees.

    This package supports the following types of graphs:

    1. graphs based on explicitly connected nodes (org.opalj.graphs.Node),
    2. graphs where the relationship between the nodes are encoded externally (org.opalj.graphs.Graph).
    Definition Classes
    opalj
  • package io

    Various io-related helper methods and classes.

    Various io-related helper methods and classes.

    Definition Classes
    opalj
    Note

    The implementations of the methods rely on Java NIO(2).

  • package issues

    Defines implicit conversions to wrap some types of analyses such that they generate results of type org.opalj.br.analyses.ReportableAnalysisResult.

    Defines implicit conversions to wrap some types of analyses such that they generate results of type org.opalj.br.analyses.ReportableAnalysisResult.

    Definition Classes
    opalj
  • package log
    Definition Classes
    opalj
  • package tac

    Common definitions related to the definition and processing of three address code.

    Common definitions related to the definition and processing of three address code.

    Definition Classes
    opalj
  • package util

    Utility methods.

    Utility methods.

    Definition Classes
    opalj
  • package value

    Provides a general query interface for querying a value's properties.

    Provides a general query interface for querying a value's properties.

    Definition Classes
    opalj
  • ABooleanValue
  • AByteValue
  • ACharValue
  • ADoubleValue
  • AFloatValue
  • ALongValue
  • AMultipleReferenceValue
  • AProperMObjectValue
  • AProperSObjectValue
  • AReturnAddressValue
  • ASArrayValue
  • ASArrayWithLengthValue
  • ASObjectValue
  • AShortValue
  • AnIntegerValue
  • BaseReferenceValues
  • BooleanValueFalse
  • BooleanValueTrue
  • ConstantValueInformationProvider
  • IsBaseReferenceValue
  • IsBooleanValue
  • IsByteValue
  • IsCharValue
  • IsClassValue
  • IsDoubleValue
  • IsFloatValue
  • IsIllegalValue
  • IsIntegerLikeValue
  • IsIntegerValue
  • IsLongValue
  • IsMObjectValue
  • IsMultipleReferenceValue
  • IsNullValue
  • IsPrimitiveValue
  • IsReferenceValue
  • IsReturnAddressValue
  • IsSArrayValue
  • IsSObjectValue
  • IsSReferenceValue
  • IsShortValue
  • IsStringValue
  • KnownTypedValue
  • KnownValue
  • TheByteValue
  • TheCharValue
  • TheClassValue
  • TheDoubleValue
  • TheFloatValue
  • TheIntegerValue
  • TheLongValue
  • TheShortValue
  • TheStringValue
  • TheVoidValue
  • TypeOfReferenceValue
  • ValueInformation

package value

Provides a general query interface for querying a value's properties.

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

Type Members

  1. case class AMultipleReferenceValue(baseValues: Iterable[IsReferenceValue], isNull: Answer, isPrecise: Boolean, upperTypeBound: UIDSet[_ <: ReferenceType], leastUpperType: Option[ReferenceType]) extends IsMultipleReferenceValue with Product with Serializable
  2. case class AProperMObjectValue(isNull: Answer, isPrecise: Boolean, upperTypeBound: UIDSet[ObjectType], leastUpperType: Option[ReferenceType]) extends IsMObjectValue with Product with Serializable

    Represents an object value which is either null or properly initialized.

  3. case class AProperSObjectValue(isNull: Answer, isPrecise: Boolean, theUpperTypeBound: ObjectType) extends IsSObjectValue with Product with Serializable

    Represents an object value which is either null or properly initialized.

  4. case class ASArrayValue(isNull: Answer, isPrecise: Boolean, theUpperTypeBound: ArrayType) extends IsSArrayValue with Product with Serializable
  5. case class ASArrayWithLengthValue(length: Int, theUpperTypeBound: ArrayType) extends IsSArrayValue with Product with Serializable
  6. case class ASObjectValue(isNull: Answer, isPrecise: Boolean, theUpperTypeBound: ObjectType) extends IsSObjectValue with Product with Serializable

    Represents some object value which may be null and may even not be properly initialized yet.

  7. trait ConstantValueInformationProvider[T] extends AnyRef

    A value for which the information is available if it is a constant – and if so which – value.

  8. trait IsBaseReferenceValue extends IsReferenceValue
  9. trait IsBooleanValue extends IsIntegerLikeValue[BooleanType]
  10. trait IsByteValue extends IsIntegerLikeValue[ByteType]
  11. trait IsCharValue extends IsIntegerLikeValue[CharType]
  12. trait IsClassValue extends IsPreciseNonNullReferenceValue with ConstantValueInformationProvider[Type]
  13. trait IsDoubleValue extends IsPrimitiveValue[DoubleType]
  14. trait IsFloatValue extends IsPrimitiveValue[FloatType]
  15. trait IsIllegalValue extends ValueInformation
  16. sealed trait IsIntegerLikeValue[T <: BaseType] extends IsPrimitiveValue[T]
  17. trait IsIntegerValue extends IsIntegerLikeValue[IntegerType]
  18. trait IsLongValue extends IsPrimitiveValue[LongType]
  19. trait IsMObjectValue extends IsBaseReferenceValue
  20. trait IsMultipleReferenceValue extends IsReferenceValue
  21. trait IsNullValue extends IsBaseReferenceValue
  22. sealed trait IsPrimitiveValue[T <: BaseType] extends KnownTypedValue with ConstantValueInformationProvider[value.IsPrimitiveValue.T.JType]

    The value has the primitive type.

  23. trait IsReferenceValue extends KnownTypedValue

    Describes the essential properties of a reference value in a program.

    Describes the essential properties of a reference value in a program.

    For example, in the following:

    val o = If(...) new Object() else "STRING"

    o is a reference value (IsReferenceValue) that (may) refers to two "simple" base values: new Object() and "STRING"; however, it is a decision of the underlying domain whether the information about the base values is made available or not. Furthermore, if the base values are actually used, the constraints in effect for the overall abstraction should be considered to get the most precise result.

  24. trait IsReturnAddressValue extends KnownTypedValue
  25. trait IsSArrayValue extends IsSReferenceValue[ArrayType]
  26. trait IsSObjectValue extends IsSReferenceValue[ObjectType]
  27. trait IsSReferenceValue[T <: ReferenceType] extends IsBaseReferenceValue
  28. trait IsShortValue extends IsIntegerLikeValue[ShortType]
  29. trait IsStringValue extends IsPreciseNonNullReferenceValue with ConstantValueInformationProvider[String]
  30. trait KnownTypedValue extends KnownValue

    A value with a well-defined computational type.

  31. sealed trait KnownValue extends ValueInformation
  32. case class TheByteValue(value: Byte) extends IsByteValue with Product with Serializable
  33. case class TheCharValue(value: Char) extends IsCharValue with Product with Serializable
  34. case class TheClassValue(value: Type) extends IsClassValue with Product with Serializable

    Represents a constant class value.

    Represents a constant class value. If the class is not yet completely initialized value is null. This can never be the case for the parameters and return values of methods and also for the values stored in fields.

  35. case class TheDoubleValue(value: Double) extends IsDoubleValue with Product with Serializable
  36. case class TheFloatValue(value: Float) extends IsFloatValue with Product with Serializable
  37. case class TheIntegerValue(value: Int) extends IsIntegerValue with Product with Serializable
  38. case class TheLongValue(value: Long) extends IsLongValue with Product with Serializable
  39. case class TheShortValue(value: Short) extends IsShortValue with Product with Serializable
  40. case class TheStringValue(value: String) extends IsStringValue with Product with Serializable

    Represents a constant string value.

    Represents a constant string value. If the string is not yet completely initialized value is null. This can never be the case for the parameters and return values of methods and also for the values stored in fields.

  41. trait ValueInformation extends AnyRef

    Encapsulates the available type information about a DomainValue.

Value Members

  1. case object ABooleanValue extends IsBooleanValue with Product with Serializable
  2. case object AByteValue extends IsByteValue with Product with Serializable
  3. case object ACharValue extends IsCharValue with Product with Serializable
  4. case object ADoubleValue extends IsDoubleValue with Product with Serializable
  5. case object AFloatValue extends IsFloatValue with Product with Serializable
  6. case object ALongValue extends IsLongValue with Product with Serializable
  7. case object AReturnAddressValue extends IsReturnAddressValue with Product with Serializable
  8. case object AShortValue extends IsShortValue with Product with Serializable
  9. case object AnIntegerValue extends IsIntegerValue with Product with Serializable
  10. object BaseReferenceValues

    Defines an extractor method for instances of IsReferenceValue objects.

    Defines an extractor method for instances of IsReferenceValue objects.

    Note

    To ensure that the generic type can be matched, it may be necessary to first cast a generic org.opalj.ai.ValuesDomain.DomainValue to a org.opalj.ai.ValuesDomain.DomainReferenceValue.

    val d : Domain = ...
    val d.DomainReferenceValue(v) = /*some domain value; e.g., operands.head*/
    val BaseReferenceValues(values) = v
    values...
  11. case object BooleanValueFalse extends IsBooleanValue with Product with Serializable
  12. case object BooleanValueTrue extends IsBooleanValue with Product with Serializable
  13. case object IsIllegalValue extends IsIllegalValue with Product with Serializable
  14. case object IsNullValue extends IsNullValue with Product with Serializable
  15. object IsPrimitiveValue
  16. object TheVoidValue extends KnownValue
  17. object TypeOfReferenceValue

    Extractor for instances of IsReferenceValue objects.

  18. object ValueInformation

Inherited from AnyRef

Inherited from Any

Ungrouped