1 /******************************************************************************* 2 * Copyright (c) 2005, 2019 IBM Corporation and others. 3 * 4 * This program and the accompanying materials 5 * are made available under the terms of the Eclipse Public License 2.0 6 * which accompanies this distribution, and is available at 7 * https://www.eclipse.org/legal/epl-2.0/ 8 * 9 * SPDX-License-Identifier: EPL-2.0 10 * 11 * Contributors: 12 * IBM Corporation - initial API and implementation 13 *******************************************************************************/ 14 package org.eclipse.pde.internal.ui.correction; 15 16 import org.eclipse.core.resources.IMarker; 17 import org.eclipse.pde.internal.core.ICoreConstants; 18 import org.eclipse.pde.internal.core.text.bundle.BundleModel; 19 import org.eclipse.pde.internal.ui.PDEUIMessages; 20 21 public class CreateJREBundleHeaderResolution extends AbstractManifestMarkerResolution { 22 CreateJREBundleHeaderResolution(int type, IMarker marker)23 public CreateJREBundleHeaderResolution(int type, IMarker marker) { 24 super(type, marker); 25 } 26 27 @Override getDescription()28 public String getDescription() { 29 return PDEUIMessages.CreateJREBundleHeaderResolution_desc; 30 } 31 32 @Override getLabel()33 public String getLabel() { 34 return PDEUIMessages.CreateJREBundleHeaderResolution_label; 35 } 36 37 @Override createChange(BundleModel model)38 protected void createChange(BundleModel model) { 39 model.getBundle().setHeader(ICoreConstants.ECLIPSE_JREBUNDLE, Boolean.toString(true)); 40 } 41 } 42