plugin.setName("MetricPlugin"); plugin.setClassName(MetricsPlugIn_name);
plugin.setName(MetricsPlugIn_name);
  private void addCollectorCD(ComponentData data) {    //Only add this if its not there already    ComponentData[] children = data.getChildren();    for (int i = 0; i < data.childCount(); i++) {      if (children[i].getClassName().equals(MetricsPlugIn_name))	return;    }    GenericComponentData plugin = new GenericComponentData();    plugin.setType(ComponentData.PLUGIN);    plugin.setName("MetricPlugin");    plugin.setClassName(MetricsPlugIn_name);    // Could add the directory to save results in as a parameter    plugin.setParent(data);    plugin.setOwner(this);    data.addChild(plugin);  }