WARNING: Compilation error, verify your source file

"; die("Please click 'back' on your browser."); } } function show_methods($list,$context,$file_name) { $acm=substr_count($list,'main([Ljava/lang/String;)V'); $acm_cmd=substr_count($list,'commandAction(Ljavax/microedition/lcdui/Command;Ljavax/microedition/lcdui/Displayable;)V'); if(substr_count($list,',')>0) { $method_signature=explode(',',$list); }else { $method_signature=explode(" ",$list); } $limit=count($method_signature); if ($limit>1) { $limit=$limit-1; } if ($acm == 1 || $acm_cmd == 1) { // there is a main or cmdAction for($i=0; $i < $limit; $i ++) { // bubble if(substr_count($method_signature[$i],'main([Ljava/lang/String;)V')==1 || substr_count($method_signature[$i],'commandAction(Ljavax/microedition/lcdui/Command;Ljavax/microedition/lcdui/Displayable;)V')==1) { $aux=$method_signature[0]; $method_signature[0]=$method_signature[$i]; $method_signature[$i]=$aux; } } if (substr_count($file_name,'x10') != 1){ ?> or Select All "; } echo "
"; for($i=0; $i < $limit; $i ++) { $method_sign=htmlentities($method_signature[$i]); if($i==0) { //if(substr_count($method_sign,'main([Ljava/lang/String;)V')==1 || substr_count($method_sign,'commandAction(Ljavax/microedition/lcdui/Command;Ljavax/microedition/lcdui/Displayable;)V')==1){ //echo " $method_signature[$i]"."
"; echo " $method_signature[$i]"."
"; } else { echo " $method_signature[$i] "."
"; } } if($context!="") { $size=strlen($context); echo "
Context Info (Classes)
"; } // else { // echo "
Context Info (Classes)
"; // } }else { // not main if (substr_count($file_name,'x10') != 1){ ?> or Select All "; } echo "
"; for($i=0; $i < $limit; $i ++) { $method_sign=htmlentities($method_signature[$i]); if($i==0) { // echo " $method_signature[$i] "."
"; echo " $method_signature[$i] "."
"; }else { // echo " $method_signature[$i] "."
"; echo " $method_signature[$i]"."
"; } } if($context!="") { $size=strlen($context); echo "
Context Info (Classes)
"; } // else { // echo "
Context Info (Classes)
"; // } } } //function parse_dot_seetings($examples,$filename){ function parse_dot_seetings($path,$filename) { $define_settings=array('-m','-c','cost_model','-u','compute_asymptotic_ub','gc_model','-p'); $flags=array(); $values_settings=array(); //$path_to_settings_file=$examples."/".$filename.".settings"; $path_to_settings_file=$path."/".$filename.".settings"; if (file_exists($path_to_settings_file)) { $values=file_get_contents($path_to_settings_file); $settings=explode(PHP_EOL,chop($values)); for($i=0;$i',$file_contents);// for($j=0; $j until //for ($i=0; $i=1){ /// looking if the flag exsits in option
  • if(substr_count($each_option_web[$j],$flags[$i])>=1) { /// looking if the flag exsits in option
  • $eachline_opt=explode(' $restline[0]=array_pop($new_value); ///
    } $tmp[0]= implode(" ",$new_value); array_splice($eachline_opt, 1,1, $tmp); $tmp[1]=implode(" ",$old_default); array_splice($eachline_opt, $pos,1, $tmp); array_splice($eachline_opt, $pos,1); } //if($i<=count($values_flags)){$each_option_web[$j]=implode('", $each_option_web); $remove1=str_replace('
  • ', '', $implode); $remove2=str_replace('', '', $remove2); $remove4=str_replace('
  • ', '', $remove3); $remove5=str_replace('', '', $remove4); $remove6=str_replace(' > ',' > ',$remove5); echo $remove6; echo ""; } ?> COSt Termination Analyzer for Java Bytecode
    COSTA: COSt and Termination Analyzer for Java Bytecode
        
        package memory.jolden.bisort;
    
    /**
     * A class that represents a value to be sorted by the <tt>BiSort</tt> 
     * algorithm.  We represents a values as a node in a binary tree.
     **/
    class Value
    {
      private int value;
      private Value left;
      private Value right;
    
      static final boolean FORWARD = false;
      static final boolean BACKWARD = true;
    
      // These are used by the Olden benchmark random no. generator
      private static final int CONST_m1 = 10000;
      private static final int CONST_b = 31415821;
      static final int RANGE = 100;
    
      /**
       * Constructor for a node representing a value in the bitonic sort tree.
       * @param v the integer value which is the sort key
       **/
      Value(int v)
      {
        value = v;
        left = right = null;
      }
    
      /**
       * Create a random tree of value to be sorted using the bitonic sorting algorithm.
       *
       * @param size the number of values to create.
       * @param seed a random number generator seed value
       * @return the root of the (sub) tree.
       **/
      static Value createTree(int size, int seed)
      {
        if (size > 1) {
          seed = random(seed);
          int next_val = seed % RANGE;
          
          Value retval = new Value(next_val);
          retval.left = createTree(size/2, seed);
          retval.right = createTree(size/2, skiprand(seed, size+1));
          return retval;
        } else {
          return null;
        }
      }
    
      /**
       * Perform a bitonic sort based upon the Bilardi and Nicolau algorithm.
       *
       * @param spr_val the "spare" value in the algorithm.
       * @param direction the direction of the sort (forward or backward)
       * @return the new "spare" value.
       **/
      int bisort(int spr_val, boolean direction)
      {
        if (left == null) {
          if ((value > spr_val) ^ direction) {
    	int tmpval = spr_val;
    	spr_val = value;
    	value = tmpval;
          }
        } else {
          int val = value;
          value = left.bisort(val, direction);
          boolean ndir = !direction;
          spr_val = right.bisort(spr_val, ndir);
          spr_val = bimerge(spr_val, direction);
        }
        return spr_val;
      }
    
      /**
       * Perform the merge part of the bitonic sort.  The merge part does
       * the actualy sorting.
       * @param spr_val the "spare" value in the algorithm.
       * @param direction the direction of the sort (forward or backward)
       * @return the new "spare" value
       **/
      int bimerge(int spr_val, boolean direction)
      {
        int   rv = value;
        Value pl = left;
        Value pr = right;
    
        boolean rightexchange = (rv > spr_val) ^ direction;
        if (rightexchange) {
          value = spr_val;
          spr_val = rv;
        }
        
        while (pl != null) {
          int   lv  = pl.value;
          Value pll = pl.left;
          Value plr = pl.right;
          rv        = pr.value;
          Value prl = pr.left;
          Value prr = pr.right;
    
          boolean elementexchange = (lv > rv) ^ direction;
          if (rightexchange) {
    	if (elementexchange) {
    	  pl.swapValRight(pr);
    	  pl = pll;
    	  pr = prl;
    	} else {
    	  pl = plr;
    	  pr = prr;
    	}
          } else {
    	if (elementexchange) {
    	  pl.swapValLeft(pr);
    	  pl = plr;
    	  pr = prr;
    	} else {
    	  pl = pll;
    	  pr = prl;
    	}
          }
        }
        
        if (left != null) {
          value = left.bimerge(value, direction);
          spr_val = right.bimerge(spr_val, direction);
        }
        return spr_val;
      }
    
      /**
       * Swap the values and the right subtrees.
       * @param n the other subtree involved in the swap.
       **/
      void swapValRight(Value n)
      {
        int   tmpv = n.value;
        Value tmpr = n.right;
    
        n.value = value;
        n.right = right;
        
        value = tmpv;
        right = tmpr;
      }
    
      /**
       * Swap the values and the left subtrees.
       * @param n the other subtree involved in the swap.
       **/
      void swapValLeft(Value n)
      {
        int   tmpv = n.value;
        Value tmpl = n.left;
        
        n.value = value;
        n.left  = left;
    
        value = tmpv;
        left  = tmpl;
      }
    
      /**
       * Print out the nodes in the binary tree in infix order.
       **/
      void inOrder()
      {
        if (left != null)
          left.inOrder();
        System.out.println(value + " " + hashCode());
        if (right != null)
          right.inOrder();
      }
      
    
      /**
       * A random generator.  The original Olden benchmark uses its
       * own random generator.  We use the same one in the Java version.
       * @return the next random number in the sequence.
       **/
      private static int mult(int p, int q)
      {
        int p1 = p/CONST_m1; 
        int p0 = p%CONST_m1;
        int q1 = q/CONST_m1; 
        int q0 = q%CONST_m1;
        return (((p0*q1+p1*q0) % CONST_m1) * CONST_m1+p0*q0);
      }
    
      /**
       * A routine to skip the next <i>n</i> random numbers.
       * @param seed the current random no. seed
       * @param n the number of numbers to skip
       **/
      private static int skiprand(int seed, int n)
      {
          for (; n > 0; n--) seed = random(seed);
          return seed;
      }
    
      /**
       * Return a random number based upon the seed value.
       * @param seed the random number seed value
       * @return a random number based upon the seed value.
       **/
      static int random(int seed)
      {
        int tmp = mult(seed, CONST_b) + 1;
        return tmp;
      }
    }