Java 类com.vmware.vim25.PerformanceDescription 实例源码

项目:vijava    文件:PrintPerfMgr.java   
public static void main(String[] args) throws Exception
{
  if(args.length != 3)
  {
    System.out.println("Usage: java PrintPerfMgr " 
      + "<url> <username> <password>");
    return;
  }

  ServiceInstance si = new ServiceInstance(
    new URL(args[0]), args[1], args[2], true);

  PerformanceManager perfMgr = si.getPerformanceManager();

  System.out.println("***Print All Descriptions:");
  PerformanceDescription pd = perfMgr.getDescription();
  printPerfDescription(pd);

  System.out.println("\n***Print All Historical Intervals:");
  PerfInterval[] pis = perfMgr.getHistoricalInterval();
  printPerfIntervals(pis);

  System.out.println("\n***Print All Perf Counters:");
  PerfCounterInfo[] pcis = perfMgr.getPerfCounter();
  printPerfCounters(pcis);

  si.getServerConnection().logout();
}
项目:vijava    文件:PrintPerfMgr.java   
static void printPerfDescription(PerformanceDescription pd)
{
  ElementDescription[] eds = pd.getCounterType();
  printElementDescriptions(eds);

  ElementDescription[] statsTypes = pd.getStatsType();
  printElementDescriptions(statsTypes);
}
项目:jcloud-vsphere    文件:PerformanceManagerApi.java   
PerformanceDescription getDescription();