if (this.deployment == PluginDeploymentType.AGENT) {
return LookupUtil.getPluginManager().getPlugin(this.name);
} else if (this.deployment == PluginDeploymentType.SERVER) {
PluginKey pluginKey = new PluginKey(this.deployment, this.pluginType, this.name);
ServerPluginManagerLocal serverPluginsBean = LookupUtil.getServerPluginManager();
ServerPlugin plugin = serverPluginsBean.getServerPlugin(pluginKey);
return serverPluginsBean.getServerPluginRelationships(plugin);
}
return null;
}