Package de.petris.dynamicaspects

Examples of de.petris.dynamicaspects.AspectException


            methodName,
            argClasses ).getModifiers();
      }
    }
    catch( Exception exc ) {
      throw new AspectException(
        "method getModifiers in "
        + Reflection.class.getName()
        + " caused an exception", exc );
    }
  }
View Full Code Here


      else {
        return Class.forName( className );
      }
    }
    catch( Exception exc ) {
      throw new AspectException(
          "method classForName in "
          + Reflection.class.getName()
          + " caused an exception", exc );
    }
  }
View Full Code Here

             innerClassName ) ) {
         return innerClass;
       }
     }
    
     throw new AspectException(
         new ClassNotFoundException( innerClassName ) );
  }
View Full Code Here

   
        try {
            return cp.parse();
        }
        catch( Throwable t ) {
            throw new AspectException(
                    "tried to load class  "
                    + className + " from a byte array ",
                    t );
        }
    }
View Full Code Here

   
      return ih[0];
     
    }
   
    throw new AspectException(
      "unexpected situation: " +
      "expected super() or this(...) statement but found none!" );
  }
View Full Code Here

   
    if( iter.hasNext() ) {
      return ((InstructionHandle[])iter.next())[0];
    }
   
    throw new AspectException(
      "unexpected situation: could not find " +
      " initialization of argument info with idx: "
      + ((Integer)argListVarIdx).toString() );
   
  }
View Full Code Here

  public void install( Class<? extends Advice> adviceClass, Pattern joinpointPattern ) {
    try {
      install( adviceClass.newInstance(), joinpointPattern );
    }
    catch( Exception exc ) {
      throw new AspectException( exc );
    }
  }
View Full Code Here

  private void handleInstall(
    Integer methodIdx, Pattern joinpointPattern,
    Advice advice, AdviceFactory factory ) {
   
        if( !( advice instanceof BeforeAfterAdvice ) ) {
            throw new AspectException(
                    "all advices installed via the "
                    + CallClassHandler.class.getName()
                    + " are expected to implement "
                    + BeforeAfterAdvice.class.getName()
                    + ", " + advice.getClass().getName()
View Full Code Here

                        BeforeAfterAdvice inner =
                            (BeforeAfterAdvice)aspectClass.newInstance();
                        return addAdvice( inner );
                    }
                    catch( Exception exc ) {
                        throw new AspectException( exc );
                    }
                }
                /* (non-Javadoc)
                 * @see de.petris.dynamicaspects.AdviceFactory#getAdviceClassName()
                 */
 
View Full Code Here

      if( localVarsGen.getName().equals( variableName ) ) {
        return localVarsGen.getIndex();
      }
    }
   
    throw new AspectException(
      "unexpected situation: could not find variable "
      +  variableName + " in local variable table!" );
   
  }
View Full Code Here

TOP

Related Classes of de.petris.dynamicaspects.AspectException

Copyright © 2018 www.massapicom. 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.