Class/Object

org.opalj.ai.domain.l0.DefaultTypeLevelReferenceValues

MObjectValue

Related Docs: object MObjectValue | package DefaultTypeLevelReferenceValues

Permalink

class MObjectValue extends (DefaultTypeLevelReferenceValues.this)#ObjectValue

Attributes
protected
Self Type
(DefaultTypeLevelReferenceValues.this)#MObjectValue with (DefaultTypeLevelReferenceValues.this)#DomainObjectValue
Linear Supertypes
Known Subclasses
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. MObjectValue
  2. ObjectValue
  3. ObjectValue
  4. ReferenceValue
  5. ArrayAbstraction
  6. IsReferenceValue
  7. IsAReferenceValue
  8. TypeInformation
  9. Value
  10. AnyRef
  11. Any
Implicitly
  1. by any2stringadd
  2. by StringFormat
  3. by Ensuring
  4. by ArrowAssoc
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new MObjectValue(upperTypeBound: UIDSet[ObjectType])

    Permalink

    upperTypeBound

    All types from which the (precise, but unknown) type of the represented value inherits. I.e., the value represented by this domain value is known to have a type that (in)directly inherits from all given types at the same time.

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. def +(other: String): String

    Permalink
    Implicit information
    This member is added by an implicit conversion from (DefaultTypeLevelReferenceValues.this)#MObjectValue to any2stringadd[(DefaultTypeLevelReferenceValues.this)#MObjectValue] performed by method any2stringadd in scala.Predef.
    Definition Classes
    any2stringadd
  4. def ->[B](y: B): ((DefaultTypeLevelReferenceValues.this)#MObjectValue, B)

    Permalink
    Implicit information
    This member is added by an implicit conversion from (DefaultTypeLevelReferenceValues.this)#MObjectValue to ArrowAssoc[(DefaultTypeLevelReferenceValues.this)#MObjectValue] performed by method ArrowAssoc in scala.Predef.
    Definition Classes
    ArrowAssoc
    Annotations
    @inline()
  5. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  6. def abstractsOver(other: (DefaultTypeLevelReferenceValues.this)#DomainValue): Boolean

    Permalink

    Returns true iff the abstract state represented by this value abstracts over the state of the given value.

    Returns true iff the abstract state represented by this value abstracts over the state of the given value. In other words if every possible runtime value represented by the given value is also represented by this value.

    The abstract state generally encompasses every information that would be considered during a join of this value and the other value and that could lead to a StructuralUpdate.

    This method is reflexive, I.e., every value abstracts over itself.

    TheIllegalValue only abstracts over itself.

    Implementation

    The default implementation relies on this domain value's join method.

    Overriding this method is, hence, primarily meaningful for performance reasons.

    Definition Classes
    Value
    See also

    isMorePreciseThan

  7. def adapt(target: TargetDomain, origin: ValueOrigin): (target)#DomainValue

    Permalink

    Adapts this value to the given domain (default: throws a domain exception that adaptation is not supported).

    Adapts this value to the given domain (default: throws a domain exception that adaptation is not supported). This method needs to be overridden by concrete Value classes to support the adaptation for a specific domain.

    Supporting the adapt method is primarily necessary when you want to analyze a method that is called by the currently analyzed method and you need to adapt this domain's values (the actual parameters of the method) to the domain used for analyzing the called method.

    Additionally, the adapt method is OPAL's main mechanism to enable dynamic domain-adaptation. I.e., to make it possible to change the abstract domain at runtime if the analysis time takes too long using a (more) precise domain.

    Definition Classes
    MObjectValueValue
    Note

    The abstract interpretation framework does not use/call this method. This method is solely predefined to facilitate the development of project-wide analyses.

  8. final def asDomainValue(implicit targetDomain: Domain): Domain.DomainReferenceValue

    Permalink

    Returns this reference value as a DomainValue of its original domain.

    Returns this reference value as a DomainValue of its original domain.

    Definition Classes
    ReferenceValueIsAReferenceValue
  9. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  10. final def asIsAReferenceValue: MObjectValue.this

    Permalink
    Definition Classes
    IsAReferenceValue
  11. def asStructuralUpdate(pc: PC, newUpperTypeBound: UIDSet[ObjectType]): Update[(DefaultTypeLevelReferenceValues.this)#DomainValue]

    Permalink
    Attributes
    protected
    Definition Classes
    ObjectValue
  12. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  13. final def computationalType: ComputationalType

    Permalink

    Returns ComputationalTypeReference.

    Returns ComputationalTypeReference.

    Definition Classes
    ReferenceValueValue
  14. def doJoin(pc: PC, other: (DefaultTypeLevelReferenceValues.this)#DomainValue): Update[(DefaultTypeLevelReferenceValues.this)#DomainValue]

    Permalink

    Joins this value and the given value.

    Joins this value and the given value.

    Join is called whenever an instruction is evaluated more than once and, hence, the values found on the paths need to be joined. This method is, however, only called if the two values are two different objects ((this ne value) === true), but both values have the same computational type.

    This basically implements the join operator of complete lattices.

    Example

    For example, joining a DomainValue that represents the integer value 0 with a DomainValue that represents the integer value 1 may return a new DomainValue that precisely captures the range [0..1] or that captures all positive integer values or just some integer value.

    Contract

    this value is always the value that was previously used to perform subsequent computations/analyses. Hence, if this value subsumes the given value, the result has to be either NoUpdate or a MetaInformationUpdate. In case that the given value subsumes this value, the result has to be a StructuralUpdate with the given value as the new value. Hence, this join operation is not commutative. If a new (more abstract) abstract value is created that represents both values the result always has to be a StructuralUpdate. If the result is a StructuralUpdate the framework will continue with the interpretation.

    The termination of the abstract interpretation directly depends on the fact that at some point all (abstract) values are fixed and don't change anymore. Hence, it is important that the type of the update is only a org.opalj.ai.StructuralUpdate if the value has changed in a way relevant for future computations/analyses involving this value. In other words, when two values are joined it has to be ensured that no fall back to a previous value occurs. E.g., if you join the existing integer value 0 and the given value 1 and the result would be 1, then it must be ensured that a subsequent join with the value 0 will not result in the value 0 again.

    Conceptually, the join of an object with itself has to return the object itself. Note, that this is a conceptual requirement as such a call (this.doJoin(..,this)) will not be performed by the abstract interpretation framework; this case is handled by the join method. However, if the join object is also used by the implementation of the domain itself, it may be necessary to explicitly handle self-joins.

    Performance

    In general, the domain should try to minimize the number of objects that it uses to represent values. That is, two values that are conceptually equal should – whenever possible – use only one object. This has a significant impact on functions such as join.

    pc

    The program counter of the instruction where the paths converge.

    Attributes
    protected
    Definition Classes
    MObjectValueValue
  15. def ensuring(cond: ((DefaultTypeLevelReferenceValues.this)#MObjectValue) ⇒ Boolean, msg: ⇒ Any): (DefaultTypeLevelReferenceValues.this)#MObjectValue

    Permalink
    Implicit information
    This member is added by an implicit conversion from (DefaultTypeLevelReferenceValues.this)#MObjectValue to Ensuring[(DefaultTypeLevelReferenceValues.this)#MObjectValue] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  16. def ensuring(cond: ((DefaultTypeLevelReferenceValues.this)#MObjectValue) ⇒ Boolean): (DefaultTypeLevelReferenceValues.this)#MObjectValue

    Permalink
    Implicit information
    This member is added by an implicit conversion from (DefaultTypeLevelReferenceValues.this)#MObjectValue to Ensuring[(DefaultTypeLevelReferenceValues.this)#MObjectValue] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  17. def ensuring(cond: Boolean, msg: ⇒ Any): (DefaultTypeLevelReferenceValues.this)#MObjectValue

    Permalink
    Implicit information
    This member is added by an implicit conversion from (DefaultTypeLevelReferenceValues.this)#MObjectValue to Ensuring[(DefaultTypeLevelReferenceValues.this)#MObjectValue] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  18. def ensuring(cond: Boolean): (DefaultTypeLevelReferenceValues.this)#MObjectValue

    Permalink
    Implicit information
    This member is added by an implicit conversion from (DefaultTypeLevelReferenceValues.this)#MObjectValue to Ensuring[(DefaultTypeLevelReferenceValues.this)#MObjectValue] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  19. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  20. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  21. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  22. def formatted(fmtstr: String): String

    Permalink
    Implicit information
    This member is added by an implicit conversion from (DefaultTypeLevelReferenceValues.this)#MObjectValue to StringFormat[(DefaultTypeLevelReferenceValues.this)#MObjectValue] performed by method StringFormat in scala.Predef.
    Definition Classes
    StringFormat
    Annotations
    @inline()
  23. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  24. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  25. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  26. def isMorePreciseThan(other: (DefaultTypeLevelReferenceValues.this)#DomainValue): Boolean

    Permalink

    Returns true iff the abstract state represented by this value is striclty more precise than the state of the given value.

    Returns true iff the abstract state represented by this value is striclty more precise than the state of the given value. In other words if every possible runtime value represented by this value is also represented by the given value, but both are not equal; in other words, this method is irreflexive.

    The considered abstract state generally encompasses every information that would be considered during a join of this value and the other value and that could lead to a StructuralUpdate.

    other

    Another DomainValue with the same computational type as this value. (The IllegalValue has no computational type and, hence, a comparison with an IllegalValue is not well defined.)

    Definition Classes
    Value
    Note

    It is recommended to overwrite this method for performance reasons, as the default implementation relies on join.

    See also

    abstractsOver

  27. def isNull: Answer

    Permalink

    If Yes the value is known to always be null at runtime.

    If Yes the value is known to always be null at runtime. In this case the upper bound is (has to be) empty. If the answer is Unknown then the analysis was not able to statically determine whether the value is null or is not null. In this case the upper bound is expected to be non-empty. If the answer is No then the value is statically known not to be null. In this case, the upper bound may precisely identify the runtime type or still just identify an upper bound.

    This default implementation always returns Unknown; this is a sound over-approximation.

    returns

    Unknown.

    Definition Classes
    IsAReferenceValue
    Note

    This method is expected to be overridden by subtypes.

  28. def isPrecise: Boolean

    Permalink

    Returns true if the type information is precise.

    Returns true if the type information is precise. I.e., the type returned by upperTypeBound precisely models the runtime type of the value. If, isPrecise returns true, the type of this value can generally be assumed to represent a class type (not an interface type) or an array type. However, this domain also supports the case that isPrecise returns true even though the associated type identifies an interface type or an abstract class type. The later case may be interesting in the context of classes that are generated at run time.

    This default implementation always returns false.

    returns

    false

    Definition Classes
    ReferenceValueIsAReferenceValue
    Note

    This method is expected to be overridden by subtypes.

    ,

    isPrecise is always true if this value is known to be null.

  29. final def isPrimitiveValue: Boolean

    Permalink
    Definition Classes
    IsReferenceValueTypeInformation
  30. final def isReferenceValue: Boolean

    Permalink
    Definition Classes
    IsReferenceValueTypeInformation
  31. def isValueSubtypeOf(supertype: ReferenceType): Answer

    Permalink

    Determines if this value is a subtype of the given supertype by delegating to the isSubtypeOf(ReferenceType,ReferenceType) method of the domain.

    Determines if this value is a subtype of the given supertype by delegating to the isSubtypeOf(ReferenceType,ReferenceType) method of the domain.

    returns

    This default implementation always returns Unknown.

    Definition Classes
    MObjectValueIsAReferenceValue
    Note

    This is a very basic implementation that cannot determine that this value is not a subtype of the given type as this implementation does not distinguish between class types and interface types.

  32. def join(pc: PC, that: (DefaultTypeLevelReferenceValues.this)#DomainValue): Update[(DefaultTypeLevelReferenceValues.this)#DomainValue]

    Permalink

    Checks that the given value and this value are compatible with regard to its computational type and – if so – calls doJoin.

    Checks that the given value and this value are compatible with regard to its computational type and – if so – calls doJoin.

    See doJoin(PC,DomainValue) for details.

    pc

    The program counter of the instruction where the paths converge.

    that

    The "new" domain value with which this domain value should be joined. The caller has to ensure that the given value and this value are guaranteed to be two different objects.

    returns

    MetaInformationUpdateIllegalValue or the result of calling doJoin.

    Definition Classes
    Value
    Note

    It is in general not recommended/needed to override this method.

  33. final def length(pc: PC): Computation[(DefaultTypeLevelReferenceValues.this)#DomainValue, (DefaultTypeLevelReferenceValues.this)#ExceptionValue]

    Permalink
    Definition Classes
    ObjectValueArrayAbstraction
  34. final def load(pc: PC, index: (DefaultTypeLevelReferenceValues.this)#DomainValue): (DefaultTypeLevelReferenceValues.this)#ArrayLoadResult

    Permalink
    Definition Classes
    ObjectValueArrayAbstraction
  35. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  36. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  37. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  38. def referenceValues: Iterable[IsAReferenceValue]

    Permalink

    In general a domain value can represent several distinct values (depending on the control flow).

    In general a domain value can represent several distinct values (depending on the control flow).

    Each of these values can have a different upper bound and an upper bound can in turn consist of several interfaces and a class.

    Definition Classes
    MObjectValueIsReferenceValue
  39. final def store(pc: PC, value: (DefaultTypeLevelReferenceValues.this)#DomainValue, index: (DefaultTypeLevelReferenceValues.this)#DomainValue): (DefaultTypeLevelReferenceValues.this)#ArrayStoreResult

    Permalink
    Definition Classes
    ObjectValueArrayAbstraction
  40. def summarize(origin: ValueOrigin): MObjectValue.this

    Permalink

    Creates a summary of this value.

    Creates a summary of this value.

    In general, creating a summary of a value may be useful/required for values that are potentially returned by a called method and which will then be used by the calling method. For example, it may be useful to precisely track the flow of values within a method to be able to distinguish between all sources of a value (E.g., to be able to distinguish between a NullPointerException created by instruction A and another one created by instruction B (A != B).) However, from the caller perspective it may be absolutely irrelevant where/how the value was created in the called method and, hence, keeping all information would just waste memory and a summary may be sufficient.

    Definition Classes
    MObjectValueValue
    Note

    This method is predefined to facilitate the development of project-wide analyses.

  41. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  42. def toString(): String

    Permalink
    Definition Classes
    MObjectValue → AnyRef → Any
  43. final def unknown: Boolean

    Permalink

    Returns true if no type information is available.

    Returns true if no type information is available.

    Definition Classes
    IsReferenceValueTypeInformation
  44. val upperTypeBound: UIDSet[ObjectType]

    Permalink

    All types from which the (precise, but unknown) type of the represented value inherits.

    All types from which the (precise, but unknown) type of the represented value inherits. I.e., the value represented by this domain value is known to have a type that (in)directly inherits from all given types at the same time.

    Definition Classes
    MObjectValueIsAReferenceValue
  45. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  46. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  47. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  48. def [B](y: B): ((DefaultTypeLevelReferenceValues.this)#MObjectValue, B)

    Permalink
    Implicit information
    This member is added by an implicit conversion from (DefaultTypeLevelReferenceValues.this)#MObjectValue to ArrowAssoc[(DefaultTypeLevelReferenceValues.this)#MObjectValue] performed by method ArrowAssoc in scala.Predef.
    Definition Classes
    ArrowAssoc

Inherited from (DefaultTypeLevelReferenceValues.this)#ObjectValue

Inherited from (DefaultTypeLevelReferenceValues.this)#ObjectValue

Inherited from (DefaultTypeLevelReferenceValues.this)#ReferenceValue

Inherited from (DefaultTypeLevelReferenceValues.this)#ArrayAbstraction

Inherited from IsReferenceValue

Inherited from IsAReferenceValue

Inherited from TypeInformation

Inherited from (DefaultTypeLevelReferenceValues.this)#Value

Inherited from AnyRef

Inherited from Any

Inherited by implicit conversion any2stringadd from (DefaultTypeLevelReferenceValues.this)#MObjectValue to any2stringadd[(DefaultTypeLevelReferenceValues.this)#MObjectValue]

Inherited by implicit conversion StringFormat from (DefaultTypeLevelReferenceValues.this)#MObjectValue to StringFormat[(DefaultTypeLevelReferenceValues.this)#MObjectValue]

Inherited by implicit conversion Ensuring from (DefaultTypeLevelReferenceValues.this)#MObjectValue to Ensuring[(DefaultTypeLevelReferenceValues.this)#MObjectValue]

Inherited by implicit conversion ArrowAssoc from (DefaultTypeLevelReferenceValues.this)#MObjectValue to ArrowAssoc[(DefaultTypeLevelReferenceValues.this)#MObjectValue]

Ungrouped