Package ch.ethz.inf.iks.jvmai.jvmdi.HotSwapSimpleClassWeaver.MethodWeaver

Examples of ch.ethz.inf.iks.jvmai.jvmdi.HotSwapSimpleClassWeaver.MethodWeaver.RedefineAdviceListEntry


     * @param cut unique identifier for the crosscut.
     * @param priority priority of the aspect holding <CODE>cut</CODE>
     */
    public void setRedefineAdvice(Method advice, Object cut, int priority) {
      if(null != advice) {
        RedefineAdviceListEntry newEntry = new RedefineAdviceListEntry(advice, cut, priority);
        addRedefineAdvice(newEntry);
      }
      else if(!redefineAdvices.isEmpty()) {
        removeRedefineAdvice(cut);
      }
View Full Code Here


      // find the entry for 'cut'
      for(
          ListIterator iter = redefineAdvices.listIterator();
          iter.hasNext();
      ) {
        RedefineAdviceListEntry e = (RedefineAdviceListEntry) iter.next();
        if(cut == e.cut) {
          // remove the entry for cut
          iter.remove();
          return true// remove only the first occurence (assume that there's only one).
        }
View Full Code Here

        // 2.a. 'proceed' statement in actual advice
        //      proceed-weaving required
        // nextAdvice might be either the next advice in the list or it's the target
        if(nextAdvices.hasNext()) {
          // 2.a.a. nextAdvice is an advice method, which need to be prepared first
          RedefineAdviceListEntry nextAdvice = (RedefineAdviceListEntry)nextAdvices.next();
          // prepare nextAdvice (RECURSION!)
          weaveRedefineAdvice(nextAdvice, nextAdvices);
        }
        // 2.a.1. save the original code of 'target' before it is redefined.
        pweaver.setTarget(methodGen, cpGen);
View Full Code Here

     *         (or a unique identifier for this cut)
     * @param priority priority of the advice holding cut
     */
    public void setRedefineAdvice(Method advice, Object cut, int priority) {
      if(null != advice) {
        RedefineAdviceListEntry newEntry = new RedefineAdviceListEntry(advice, cut, priority);
        addRedefineAdvice(newEntry);
      }
      else if(!redefineAdvices.isEmpty()) {
        removeRedefineAdvice(cut);
      }
View Full Code Here

      // find the entry for 'cut'
      for(
          ListIterator iter = redefineAdvices.listIterator();
          iter.hasNext();
      ) {
        RedefineAdviceListEntry e = (RedefineAdviceListEntry) iter.next();
        if(cut == e.cut) {
          // remove the entry for cut
          iter.remove();
          break// just remove the first occurence (assume that there's only one).
        }
View Full Code Here

        // 2.a. 'proceed' statement in actual advice
        //      proceed-weaving required
        // nextAdvice might be either the next advice in the list or it's the target
        if(nextAdvices.hasNext()) {
          // 2.a.a. nextAdvice is an advice method, which need to be prepared first
          RedefineAdviceListEntry nextAdvice = (RedefineAdviceListEntry)nextAdvices.next();
          // prepare nextAdvice (RECURSION!)
          weaveRedefineAdvice(nextAdvice, nextAdvices);
        }
        // 2.a.1. save the original code of 'target' before it is redefined.
        pweaver.setTarget(methodGen, cpGen);
View Full Code Here

TOP

Related Classes of ch.ethz.inf.iks.jvmai.jvmdi.HotSwapSimpleClassWeaver.MethodWeaver.RedefineAdviceListEntry

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.