static void set_object_argument(app_PluginRef &plugin, const std::string &struct_name) {
  app_PluginObjectInputRef pdef(plugin.get_grt());

  pdef->objectStructName(struct_name);
  pdef->owner(plugin);

  plugin->inputValues().insert(pdef);
}
grt::BaseListRef ArgumentPool::build_argument_list(const app_PluginRef &plugin)
{
  // build the argument list
  grt::BaseListRef fargs(plugin->get_grt());
  
  const size_t c= plugin->inputValues().count();
  for (size_t i= 0; i < c; i++)
  {
    app_PluginInputDefinitionRef pdef(plugin->inputValues().get(i));
    std::string searched_key;
    grt::ValueRef argument= find_match(pdef, searched_key);
    if (!argument.is_valid())
    {
      log_warning("Cannot satisfy plugin input for %s: %s", plugin->name().c_str(), searched_key.c_str());
      log_warning("Missing input: %s", pdef.repr().c_str());
      
      throw grt::grt_runtime_error("Cannot execute "+*plugin->name(),
                                   "Plugin requires unavailable argument value.");
    }
    fargs.ginsert(argument);
  }  
  return fargs;
}