Class PropositionalTransformer

  • All Implemented Interfaces:
    Transformer<net.sf.tweety.logics.pl.syntax.PlFormula>

    public final class PropositionalTransformer
    extends AbstractTransformer<net.sf.tweety.logics.pl.syntax.PlFormula,​Void,​net.sf.tweety.logics.pl.syntax.PlFormula>
    Transforms an AcceptanceCondition into a PlFormula.

    Most of the transformation is a 1:1 mapping between the structures since they are quite similar, except for EquivalenceAcceptanceCondition which allows for a compact representation of pairwise equivalences.

    Author:
    Mathias Hofer
    • Constructor Detail

      • PropositionalTransformer

        public PropositionalTransformer​(Function<Argument,​net.sf.tweety.logics.pl.syntax.Proposition> argumentMapping)
        Parameters:
        argumentMapping - the argument to proposition mapping
    • Method Detail

      • initialize

        protected Void initialize()
        Description copied from class: AbstractTransformer
        Provides the initial top-down data.
        Specified by:
        initialize in class AbstractTransformer<net.sf.tweety.logics.pl.syntax.PlFormula,​Void,​net.sf.tweety.logics.pl.syntax.PlFormula>
        Returns:
        the initial top-down data
      • finish

        protected net.sf.tweety.logics.pl.syntax.PlFormula finish​(net.sf.tweety.logics.pl.syntax.PlFormula bottomUpData,
                                                                  Void topDownData)
        Specified by:
        finish in class AbstractTransformer<net.sf.tweety.logics.pl.syntax.PlFormula,​Void,​net.sf.tweety.logics.pl.syntax.PlFormula>
      • transformDisjunction

        protected net.sf.tweety.logics.pl.syntax.PlFormula transformDisjunction​(Collection<net.sf.tweety.logics.pl.syntax.PlFormula> children,
                                                                                Void topDownData,
                                                                                int polarity)
        Specified by:
        transformDisjunction in class AbstractTransformer<net.sf.tweety.logics.pl.syntax.PlFormula,​Void,​net.sf.tweety.logics.pl.syntax.PlFormula>
      • transformConjunction

        protected net.sf.tweety.logics.pl.syntax.PlFormula transformConjunction​(Collection<net.sf.tweety.logics.pl.syntax.PlFormula> children,
                                                                                Void topDownData,
                                                                                int polarity)
        Specified by:
        transformConjunction in class AbstractTransformer<net.sf.tweety.logics.pl.syntax.PlFormula,​Void,​net.sf.tweety.logics.pl.syntax.PlFormula>
      • transformImplication

        protected net.sf.tweety.logics.pl.syntax.PlFormula transformImplication​(net.sf.tweety.logics.pl.syntax.PlFormula left,
                                                                                net.sf.tweety.logics.pl.syntax.PlFormula right,
                                                                                Void topDownData,
                                                                                int polarity)
        Specified by:
        transformImplication in class AbstractTransformer<net.sf.tweety.logics.pl.syntax.PlFormula,​Void,​net.sf.tweety.logics.pl.syntax.PlFormula>
      • transformEquivalence

        protected net.sf.tweety.logics.pl.syntax.PlFormula transformEquivalence​(Collection<net.sf.tweety.logics.pl.syntax.PlFormula> children,
                                                                                Void topDownData,
                                                                                int polarity)
        Specified by:
        transformEquivalence in class AbstractTransformer<net.sf.tweety.logics.pl.syntax.PlFormula,​Void,​net.sf.tweety.logics.pl.syntax.PlFormula>
      • transformExclusiveDisjunction

        protected net.sf.tweety.logics.pl.syntax.PlFormula transformExclusiveDisjunction​(net.sf.tweety.logics.pl.syntax.PlFormula left,
                                                                                         net.sf.tweety.logics.pl.syntax.PlFormula right,
                                                                                         Void topDownData,
                                                                                         int polarity)
        Specified by:
        transformExclusiveDisjunction in class AbstractTransformer<net.sf.tweety.logics.pl.syntax.PlFormula,​Void,​net.sf.tweety.logics.pl.syntax.PlFormula>
      • transformNegation

        protected net.sf.tweety.logics.pl.syntax.PlFormula transformNegation​(net.sf.tweety.logics.pl.syntax.PlFormula child,
                                                                             Void topDownData,
                                                                             int polarity)
        Specified by:
        transformNegation in class AbstractTransformer<net.sf.tweety.logics.pl.syntax.PlFormula,​Void,​net.sf.tweety.logics.pl.syntax.PlFormula>
      • transformArgument

        protected net.sf.tweety.logics.pl.syntax.PlFormula transformArgument​(Argument argument,
                                                                             Void topDownData,
                                                                             int polarity)
        Specified by:
        transformArgument in class AbstractTransformer<net.sf.tweety.logics.pl.syntax.PlFormula,​Void,​net.sf.tweety.logics.pl.syntax.PlFormula>
      • transformContradiction

        protected net.sf.tweety.logics.pl.syntax.PlFormula transformContradiction​(Void topDownData,
                                                                                  int polarity)
        Specified by:
        transformContradiction in class AbstractTransformer<net.sf.tweety.logics.pl.syntax.PlFormula,​Void,​net.sf.tweety.logics.pl.syntax.PlFormula>
      • transformTautology

        protected net.sf.tweety.logics.pl.syntax.PlFormula transformTautology​(Void topDownData,
                                                                              int polarity)
        Specified by:
        transformTautology in class AbstractTransformer<net.sf.tweety.logics.pl.syntax.PlFormula,​Void,​net.sf.tweety.logics.pl.syntax.PlFormula>