Examples of MethodSideEffectCall


Examples of ch.epfl.labos.iu.orm.queryll2.path.MethodSideEffectCall

               {
                  OperationSideEffect sideEffect = methodChecker.isMethodSafe(sig, base, args);
                  if (sideEffect == OperationSideEffect.UNSAFE)
                     throw new AnalyzerException(insn, "Unknown method " + sig + " encountered");
                  else if (sideEffect == OperationSideEffect.SAFE)
                     sideEffects.add(new MethodSideEffectCall(sig, base, args));
               }
               MethodCallValue.VirtualMethodCallValue toReturn;
               toReturn = new MethodCallValue.VirtualMethodCallValue(methodInsn.owner, methodInsn.name, methodInsn.desc, args, base);
               if (toReturn.isConstructor() && linkedFrame != null)
                  linkedFrame.replaceValues(base, toReturn);
               else if (methodChecker != null && methodChecker.isFluentChaining(sig))
                  linkedFrame.replaceValues(base, toReturn);
               return toReturn;
            }
            else
            {
               if (methodChecker != null)
               {
                  OperationSideEffect sideEffect = methodChecker.isStaticMethodSafe(sig);
                  if (sideEffect == OperationSideEffect.UNSAFE)
                     throw new AnalyzerException(insn, "Unknown method " + sig + " encountered");
                  else if (sideEffect == OperationSideEffect.SAFE)
                     sideEffects.add(new MethodSideEffectCall(sig, null, args));
               }
               return new MethodCallValue.StaticMethodCallValue(methodInsn.owner, methodInsn.name, methodInsn.desc, args);
            }
         }
         case INVOKEDYNAMIC:
View Full Code Here

Examples of ch.epfl.labos.iu.orm.queryll2.path.MethodSideEffectCall

      if (analysis.paths.size() != 1) throw new QueryTransformException("Symbolic execution of constructor failed");
      for (MethodSideEffect effect: analysis.paths.get(0).getSideEffects())
      {
         if (effect instanceof MethodSideEffectCall)
         {
            MethodSideEffectCall call = (MethodSideEffectCall) effect;
            if (call.m.equals(abstractFunction1Constructor)) continue;
         }
         else if (effect instanceof MethodSideEffectFieldAssign)
         {
            // Assigning to local fields is safe as long as the constructed object doesn't escape the lambda.
View Full Code Here

Examples of ch.epfl.labos.iu.orm.queryll2.path.MethodSideEffectCall

      {
         for (MethodSideEffect effect: path.getSideEffects())
         {
            if (effect instanceof MethodSideEffectCall)
            {
               MethodSideEffectCall call = (MethodSideEffectCall)effect;
               if (!call.m.name.equals("<init>"))
                  throw new QueryTransformException("Lambda has a side-effect that can't be emulated with a database query");
               try {
                  TransformationClassAnalyzer classAnalyzer =
                        new TransformationClassAnalyzer(call.m.owner, alternateClassLoader);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.