Class CartesianProduct<C extends CartesianProduct<C,​T1,​T2,​E,​I>,​T1 extends it.unive.lisa.analysis.SemanticDomain<T1,​E,​I> & it.unive.lisa.analysis.Lattice<T1>,​T2 extends it.unive.lisa.analysis.SemanticDomain<T2,​E,​I> & it.unive.lisa.analysis.Lattice<T2>,​E extends it.unive.lisa.symbolic.SymbolicExpression,​I extends it.unive.lisa.symbolic.value.Identifier>

  • Type Parameters:
    C - the concrete type of the Cartesian product
    T1 - the concrete instance of the left-hand side abstract domain of the Cartesian product
    T2 - the concrete instance of the right-hand side abstract domain of the Cartesian product
    E - the type of SymbolicExpression that <T1> and <T2>, and in turn this domain, can process
    I - the type of Identifier that <T1> and <T2>, and in turn this domain, handle
    All Implemented Interfaces:
    it.unive.lisa.analysis.Lattice<C>, it.unive.lisa.analysis.ScopedObject<C>, it.unive.lisa.analysis.SemanticDomain<C,​E,​I>, it.unive.lisa.util.representation.StructuredObject
    Direct Known Subclasses:
    ValueCartesianProduct

    public abstract class CartesianProduct<C extends CartesianProduct<C,​T1,​T2,​E,​I>,​T1 extends it.unive.lisa.analysis.SemanticDomain<T1,​E,​I> & it.unive.lisa.analysis.Lattice<T1>,​T2 extends it.unive.lisa.analysis.SemanticDomain<T2,​E,​I> & it.unive.lisa.analysis.Lattice<T2>,​E extends it.unive.lisa.symbolic.SymbolicExpression,​I extends it.unive.lisa.symbolic.value.Identifier>
    extends java.lang.Object
    implements it.unive.lisa.analysis.SemanticDomain<C,​E,​I>, it.unive.lisa.analysis.Lattice<C>
    A generic Cartesian product abstract domain between two non-communicating SemanticDomains (i.e., no exchange of information between the abstract domains), assigning the same Identifiers and handling instances of the same SymbolicExpressions.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      T1 left
      The left-hand side abstract domain.
      T2 right
      The right-hand side abstract domain.
      • Fields inherited from interface it.unive.lisa.analysis.Lattice

        BOTTOM_STRING, TOP_STRING
    • Constructor Summary

      Constructors 
      Constructor Description
      CartesianProduct​(T1 left, T2 right)
      Builds the Cartesian product abstract domain.
    • Method Summary

      All Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      C assign​(I id, E expression, it.unive.lisa.program.cfg.ProgramPoint pp, it.unive.lisa.analysis.SemanticOracle oracle)  
      C assume​(E expression, it.unive.lisa.program.cfg.ProgramPoint src, it.unive.lisa.program.cfg.ProgramPoint dest, it.unive.lisa.analysis.SemanticOracle oracle)  
      C bottom()  
      boolean equals​(java.lang.Object obj)  
      C forgetIdentifier​(it.unive.lisa.symbolic.value.Identifier id)  
      C forgetIdentifiersIf​(java.util.function.Predicate<it.unive.lisa.symbolic.value.Identifier> test)  
      <T extends it.unive.lisa.analysis.SemanticDomain<?,​?,​?>>
      java.util.Collection<T>
      getAllDomainInstances​(java.lang.Class<T> domain)  
      int hashCode()  
      boolean isBottom()  
      boolean isTop()  
      boolean lessOrEqual​(C other)  
      C lub​(C other)  
      abstract C mk​(T1 left, T2 right)
      Builds a new instance of Cartesian product.
      C popScope​(it.unive.lisa.analysis.ScopeToken scope)  
      C pushScope​(it.unive.lisa.analysis.ScopeToken scope)  
      it.unive.lisa.util.representation.StructuredRepresentation representation()  
      it.unive.lisa.analysis.lattices.Satisfiability satisfies​(E expression, it.unive.lisa.program.cfg.ProgramPoint pp, it.unive.lisa.analysis.SemanticOracle oracle)  
      C smallStepSemantics​(E expression, it.unive.lisa.program.cfg.ProgramPoint pp, it.unive.lisa.analysis.SemanticOracle oracle)  
      C top()  
      java.lang.String toString()  
      C widening​(C other)  
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface it.unive.lisa.analysis.Lattice

        glb, narrowing
      • Methods inherited from interface it.unive.lisa.analysis.SemanticDomain

        forgetIdentifiers, getDomainInstance, knowsIdentifier
    • Field Detail

      • left

        public final T1 extends it.unive.lisa.analysis.SemanticDomain<T1,​E,​I> & it.unive.lisa.analysis.Lattice<T1> left
        The left-hand side abstract domain.
      • right

        public final T2 extends it.unive.lisa.analysis.SemanticDomain<T2,​E,​I> & it.unive.lisa.analysis.Lattice<T2> right
        The right-hand side abstract domain.
    • Constructor Detail

      • CartesianProduct

        public CartesianProduct​(T1 left,
                                T2 right)
        Builds the Cartesian product abstract domain.
        Parameters:
        left - the left-hand side of the Cartesian product
        right - the right-hand side of the Cartesian product
    • Method Detail

      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • mk

        public abstract C mk​(T1 left,
                             T2 right)
        Builds a new instance of Cartesian product.
        Parameters:
        left - the first domain
        right - the second domain
        Returns:
        the new instance of product
      • representation

        public it.unive.lisa.util.representation.StructuredRepresentation representation()
        Specified by:
        representation in interface it.unive.lisa.util.representation.StructuredObject
      • assign

        public C assign​(I id,
                        E expression,
                        it.unive.lisa.program.cfg.ProgramPoint pp,
                        it.unive.lisa.analysis.SemanticOracle oracle)
                 throws it.unive.lisa.analysis.SemanticException
        Specified by:
        assign in interface it.unive.lisa.analysis.SemanticDomain<C extends CartesianProduct<C,​T1,​T2,​E,​I>,​T1 extends it.unive.lisa.analysis.SemanticDomain<T1,​E,​I> & it.unive.lisa.analysis.Lattice<T1>,​T2 extends it.unive.lisa.analysis.SemanticDomain<T2,​E,​I> & it.unive.lisa.analysis.Lattice<T2>>
        Throws:
        it.unive.lisa.analysis.SemanticException
      • smallStepSemantics

        public C smallStepSemantics​(E expression,
                                    it.unive.lisa.program.cfg.ProgramPoint pp,
                                    it.unive.lisa.analysis.SemanticOracle oracle)
                             throws it.unive.lisa.analysis.SemanticException
        Specified by:
        smallStepSemantics in interface it.unive.lisa.analysis.SemanticDomain<C extends CartesianProduct<C,​T1,​T2,​E,​I>,​T1 extends it.unive.lisa.analysis.SemanticDomain<T1,​E,​I> & it.unive.lisa.analysis.Lattice<T1>,​T2 extends it.unive.lisa.analysis.SemanticDomain<T2,​E,​I> & it.unive.lisa.analysis.Lattice<T2>>
        Throws:
        it.unive.lisa.analysis.SemanticException
      • assume

        public C assume​(E expression,
                        it.unive.lisa.program.cfg.ProgramPoint src,
                        it.unive.lisa.program.cfg.ProgramPoint dest,
                        it.unive.lisa.analysis.SemanticOracle oracle)
                 throws it.unive.lisa.analysis.SemanticException
        Specified by:
        assume in interface it.unive.lisa.analysis.SemanticDomain<C extends CartesianProduct<C,​T1,​T2,​E,​I>,​T1 extends it.unive.lisa.analysis.SemanticDomain<T1,​E,​I> & it.unive.lisa.analysis.Lattice<T1>,​T2 extends it.unive.lisa.analysis.SemanticDomain<T2,​E,​I> & it.unive.lisa.analysis.Lattice<T2>>
        Throws:
        it.unive.lisa.analysis.SemanticException
      • forgetIdentifier

        public C forgetIdentifier​(it.unive.lisa.symbolic.value.Identifier id)
                           throws it.unive.lisa.analysis.SemanticException
        Specified by:
        forgetIdentifier in interface it.unive.lisa.analysis.SemanticDomain<C extends CartesianProduct<C,​T1,​T2,​E,​I>,​T1 extends it.unive.lisa.analysis.SemanticDomain<T1,​E,​I> & it.unive.lisa.analysis.Lattice<T1>,​T2 extends it.unive.lisa.analysis.SemanticDomain<T2,​E,​I> & it.unive.lisa.analysis.Lattice<T2>>
        Throws:
        it.unive.lisa.analysis.SemanticException
      • forgetIdentifiersIf

        public C forgetIdentifiersIf​(java.util.function.Predicate<it.unive.lisa.symbolic.value.Identifier> test)
                              throws it.unive.lisa.analysis.SemanticException
        Specified by:
        forgetIdentifiersIf in interface it.unive.lisa.analysis.SemanticDomain<C extends CartesianProduct<C,​T1,​T2,​E,​I>,​T1 extends it.unive.lisa.analysis.SemanticDomain<T1,​E,​I> & it.unive.lisa.analysis.Lattice<T1>,​T2 extends it.unive.lisa.analysis.SemanticDomain<T2,​E,​I> & it.unive.lisa.analysis.Lattice<T2>>
        Throws:
        it.unive.lisa.analysis.SemanticException
      • pushScope

        public C pushScope​(it.unive.lisa.analysis.ScopeToken scope)
                    throws it.unive.lisa.analysis.SemanticException
        Specified by:
        pushScope in interface it.unive.lisa.analysis.ScopedObject<C extends CartesianProduct<C,​T1,​T2,​E,​I>>
        Throws:
        it.unive.lisa.analysis.SemanticException
      • popScope

        public C popScope​(it.unive.lisa.analysis.ScopeToken scope)
                   throws it.unive.lisa.analysis.SemanticException
        Specified by:
        popScope in interface it.unive.lisa.analysis.ScopedObject<C extends CartesianProduct<C,​T1,​T2,​E,​I>>
        Throws:
        it.unive.lisa.analysis.SemanticException
      • satisfies

        public it.unive.lisa.analysis.lattices.Satisfiability satisfies​(E expression,
                                                                        it.unive.lisa.program.cfg.ProgramPoint pp,
                                                                        it.unive.lisa.analysis.SemanticOracle oracle)
                                                                 throws it.unive.lisa.analysis.SemanticException
        Specified by:
        satisfies in interface it.unive.lisa.analysis.SemanticDomain<C extends CartesianProduct<C,​T1,​T2,​E,​I>,​T1 extends it.unive.lisa.analysis.SemanticDomain<T1,​E,​I> & it.unive.lisa.analysis.Lattice<T1>,​T2 extends it.unive.lisa.analysis.SemanticDomain<T2,​E,​I> & it.unive.lisa.analysis.Lattice<T2>>
        Throws:
        it.unive.lisa.analysis.SemanticException
      • lub

        public C lub​(C other)
              throws it.unive.lisa.analysis.SemanticException
        Specified by:
        lub in interface it.unive.lisa.analysis.Lattice<C extends CartesianProduct<C,​T1,​T2,​E,​I>>
        Throws:
        it.unive.lisa.analysis.SemanticException
      • widening

        public C widening​(C other)
                   throws it.unive.lisa.analysis.SemanticException
        Specified by:
        widening in interface it.unive.lisa.analysis.Lattice<C extends CartesianProduct<C,​T1,​T2,​E,​I>>
        Throws:
        it.unive.lisa.analysis.SemanticException
      • lessOrEqual

        public boolean lessOrEqual​(C other)
                            throws it.unive.lisa.analysis.SemanticException
        Specified by:
        lessOrEqual in interface it.unive.lisa.analysis.Lattice<C extends CartesianProduct<C,​T1,​T2,​E,​I>>
        Throws:
        it.unive.lisa.analysis.SemanticException
      • top

        public C top()
        Specified by:
        top in interface it.unive.lisa.analysis.Lattice<C extends CartesianProduct<C,​T1,​T2,​E,​I>>
      • isTop

        public boolean isTop()
        Specified by:
        isTop in interface it.unive.lisa.analysis.Lattice<C extends CartesianProduct<C,​T1,​T2,​E,​I>>
      • bottom

        public C bottom()
        Specified by:
        bottom in interface it.unive.lisa.analysis.Lattice<C extends CartesianProduct<C,​T1,​T2,​E,​I>>
      • isBottom

        public boolean isBottom()
        Specified by:
        isBottom in interface it.unive.lisa.analysis.Lattice<C extends CartesianProduct<C,​T1,​T2,​E,​I>>
      • getAllDomainInstances

        public <T extends it.unive.lisa.analysis.SemanticDomain<?,​?,​?>> java.util.Collection<T> getAllDomainInstances​(java.lang.Class<T> domain)
        Specified by:
        getAllDomainInstances in interface it.unive.lisa.analysis.SemanticDomain<C extends CartesianProduct<C,​T1,​T2,​E,​I>,​T1 extends it.unive.lisa.analysis.SemanticDomain<T1,​E,​I> & it.unive.lisa.analysis.Lattice<T1>,​T2 extends it.unive.lisa.analysis.SemanticDomain<T2,​E,​I> & it.unive.lisa.analysis.Lattice<T2>>