Class PowerMockExpressionEditor

java.lang.Object
javassist.expr.ExprEditor
org.powermock.core.transformers.javassist.support.PowerMockExpressionEditor

public final class PowerMockExpressionEditor extends javassist.expr.ExprEditor
  • Field Details

    • clazz

      private final javassist.CtClass clazz
    • mockGetawayClass

      private final Class<?> mockGetawayClass
    • strategy

      private final TransformStrategy strategy
  • Constructor Details

    • PowerMockExpressionEditor

      public PowerMockExpressionEditor(TransformStrategy strategy, javassist.CtClass clazz, Class<?> mockGetawayClass)
  • Method Details

    • edit

      public void edit(javassist.expr.NewExpr e) throws javassist.CannotCompileException
      Overrides:
      edit in class javassist.expr.ExprEditor
      Throws:
      javassist.CannotCompileException
    • edit

      public void edit(javassist.expr.MethodCall m) throws javassist.CannotCompileException
      Overrides:
      edit in class javassist.expr.ExprEditor
      Throws:
      javassist.CannotCompileException
    • edit

      public void edit(javassist.expr.ConstructorCall c) throws javassist.CannotCompileException
      Overrides:
      edit in class javassist.expr.ExprEditor
      Throws:
      javassist.CannotCompileException
    • edit

      public void edit(javassist.expr.FieldAccess f) throws javassist.CannotCompileException
      Overrides:
      edit in class javassist.expr.ExprEditor
      Throws:
      javassist.CannotCompileException
    • addNewDeferConstructor

      private void addNewDeferConstructor(javassist.CtClass clazz) throws javassist.CannotCompileException
      Create a defer constructor in the class which will be called when the constructor is suppressed.
      Parameters:
      clazz - The class whose super constructor will get a new defer constructor if it doesn't already have one.
      Throws:
      javassist.CannotCompileException - If an unexpected compilation error occurs.