public boolean isValid(Bundle bundle) throws UpdateException { if (info.getId() == null){ throw new UpdateException(info.getId(), updateFileLocation, "No plugin ID given"); } if (bundle != null){ final String pluginID = bundle.getSymbolicName(); if (!info.getId().equals(pluginID)){ throw new UpdateException(info.getId(), updateFileLocation, "ID does not match the plugin (" + pluginID + ")"); } } if (info.getAvailableVersion() == null){ throw new UpdateException(info.getId(), updateFileLocation, "Cannot find version"); } if (info.getDownloadURL() == null){ throw new UpdateException(info.getId(), updateFileLocation, "No download location given"); } return true; }
public boolean isValid(Bundle bundle) throws UpdateException { if (info.getId() == null){ throw new UpdateException(info.getId(), updateFileLocation, "No plugin ID given"); } if (bundle != null){ final String pluginID = bundle.getSymbolicName(); if (!info.getId().equals(pluginID)){ throw new UpdateException(info.getId(), updateFileLocation, "ID does not match the plugin (" + pluginID + ")"); } } if (info.getAvailableVersion() == null){ throw new UpdateException(info.getId(), updateFileLocation, "Cannot find version"); } if (info.getDownloadURL() == null){ throw new UpdateException(info.getId(), updateFileLocation, "No download location given"); } return true; }