* This method is API used by CloudFoundry Code.
*/
public CloudFoundryServer getCloudFoundryServer() throws CoreException {
Server server = (Server) getServer();
CloudFoundryServer cloudFoundryServer = (CloudFoundryServer) server.loadAdapter(CloudFoundryServer.class, null);
if (cloudFoundryServer == null) {
throw new CoreException(new Status(IStatus.ERROR, CloudFoundryPlugin.PLUGIN_ID, "Fail to load server")); //$NON-NLS-1$
}
return cloudFoundryServer;
}