Index: trunk/src/VBox/Main/webservice/webtest.cpp
===================================================================
--- trunk/src/VBox/Main/webservice/webtest.cpp	(revision 29957)
+++ trunk/src/VBox/Main/webservice/webtest.cpp	(revision 29960)
@@ -49,4 +49,5 @@
                "   - webtest version <vboxref>: IVirtualBox::getVersion().\n"
                "   - webtest gethost <vboxref>: IVirtualBox::getHost().\n"
+               "   - webtest getpc <vboxref>: IVirtualBox::getPerformanceCollector().\n"
                "   - webtest getmachines <vboxref>: IVirtualBox::getMachines().\n"
                "   - webtest createmachine <vboxref> <baseFolder> <name>: IVirtualBox::createMachine().\n"
@@ -61,4 +62,7 @@
                "   - webtest getostype <machineref>: IMachine::getGuestOSType().\n"
                "   - webtest savesettings <machineref>: IMachine::saveSettings().\n"
+               " - IPerformanceCollector:\n"
+               "   - webtest setupmetrics <pcref>: IPerformanceCollector::setupMetrics()\n"
+               "   - webtest querymetricsdata <pcref>: IPerformanceCollector::QueryMetricsData()\n"
                " - All managed object references:\n"
                "   - webtest getif <ref>: report interface of object.\n"
@@ -164,4 +168,24 @@
             {
                 std::cout << "Host objref " << resp.returnval << "\n";
+            }
+        }
+    }
+    else if (!strcmp(pcszMode, "getpc"))
+    {
+        if (argc < 3)
+            std::cout << "Not enough arguments for \"" << pcszMode << "\" mode.\n";
+        else
+        {
+            _vbox__IVirtualBox_USCOREgetPerformanceCollector req;
+            req._USCOREthis = argv[2];
+            _vbox__IVirtualBox_USCOREgetPerformanceCollectorResponse resp;
+
+            if (!(soaprc = soap_call___vbox__IVirtualBox_USCOREgetPerformanceCollector(&soap,
+                                                            pcszArgEndpoint,
+                                                            NULL,
+                                                            &req,
+                                                            &resp)))
+            {
+                std::cout << "Performance collector objref " << resp.returnval << "\n";
             }
         }
@@ -325,4 +349,60 @@
         }
     }
+    else if (!strcmp(pcszMode, "setupmetrics"))
+    {
+        if (argc < 3)
+            std::cout << "Not enough arguments for \"" << pcszMode << "\" mode.\n";
+        else
+        {
+            _vbox__IPerformanceCollector_USCOREsetupMetrics req;
+            req._USCOREthis = argv[2];
+//             req.metricNames[0] = "*";
+//             req.objects
+            req.period = 1;     // seconds
+            req.count = 100;
+            _vbox__IPerformanceCollector_USCOREsetupMetricsResponse resp;
+            if (!(soaprc = soap_call___vbox__IPerformanceCollector_USCOREsetupMetrics(&soap,
+                                                              pcszArgEndpoint,
+                                                              NULL,
+                                                              &req,
+                                                              &resp)))
+            {
+                size_t c = resp.returnval.size();
+                for (size_t i = 0;
+                     i < c;
+                     ++i)
+                {
+                    std::cout << "Metric " << i << ": objref " << resp.returnval[i] << "\n";
+                }
+            }
+        }
+    }
+    else if (!strcmp(pcszMode, "querymetricsdata"))
+    {
+        if (argc < 3)
+            std::cout << "Not enough arguments for \"" << pcszMode << "\" mode.\n";
+        else
+        {
+            _vbox__IPerformanceCollector_USCOREqueryMetricsData req;
+            req._USCOREthis = argv[2];
+//             req.metricNames[0] = "*";
+//             req.objects
+            _vbox__IPerformanceCollector_USCOREqueryMetricsDataResponse resp;
+            if (!(soaprc = soap_call___vbox__IPerformanceCollector_USCOREqueryMetricsData(&soap,
+                                                              pcszArgEndpoint,
+                                                              NULL,
+                                                              &req,
+                                                              &resp)))
+            {
+                size_t c = resp.returnval.size();
+                for (size_t i = 0;
+                     i < c;
+                     ++i)
+                {
+                    std::cout << "long " << i << ": " << resp.returnval[i] << "\n";
+                }
+            }
+        }
+    }
     else if (!strcmp(pcszMode, "release"))
     {
