Ejemplo n.º 1
0
void JavaCalls::call_static(JavaValue* result, KlassHandle klass, Symbol* name, Symbol* signature, JavaCallArguments* args, TRAPS) {
  CallInfo callinfo;
  LinkInfo link_info(klass, name, signature);
  LinkResolver::resolve_static_call(callinfo, link_info, true, CHECK);
  methodHandle method = callinfo.selected_method();
  assert(method.not_null(), "should have thrown exception");

  // Invoke the method
  JavaCalls::call(result, method, args, CHECK);
}
Ejemplo n.º 2
0
void JavaCalls::call_virtual(JavaValue* result, KlassHandle spec_klass, Symbol* name, Symbol* signature, JavaCallArguments* args, TRAPS) {
  CallInfo callinfo;
  Handle receiver = args->receiver();
  KlassHandle recvrKlass(THREAD, receiver.is_null() ? (Klass*)NULL : receiver->klass());
  LinkInfo link_info(spec_klass, name, signature);
  LinkResolver::resolve_virtual_call(
          callinfo, receiver, recvrKlass, link_info, true, CHECK);
  methodHandle method = callinfo.selected_method();
  assert(method.not_null(), "should have thrown exception");

  // Invoke the method
  JavaCalls::call(result, method, args, CHECK);
}
Ejemplo n.º 3
0
void info_about_all_links(const imap &r)
{
	list<link_info> k;
	for(imap::const_iterator i = r.begin(); i!=r.end(); i++)
		k.push_back(link_info(r, i->first));
	k.sort();

	cout<<"     Link Name          Unique Visits    Return Visits   Total Visits"<<endl;
	cout<<"--------------------    -------------    -------------   ------------"<<endl;
	for(list<link_info>::iterator i = k.begin(); i!=k.end(); i++)
	{
		cout.setf(ios::left);
		cout<<setw(20)<<i->name()<<"          ";
		cout<<setw(17)<<i->unique();
		cout<<setw(15)<<i->returning();
		cout<<i->total();
		cout<<endl;
	}
}