1 11 package org.eclipse.pde.internal.core.schema; 12 13 import org.eclipse.pde.internal.core.ischema.ISchemaObject; 14 import org.eclipse.pde.internal.core.ischema.ISchemaRootElement; 15 16 public class SchemaRootElement extends SchemaElement implements 17 ISchemaRootElement { 18 19 private static final long serialVersionUID = 1L; 20 public static final String P_DEP_REPLACEMENT = "replacement"; private String fDeperecatedReplacement; 22 23 public SchemaRootElement(ISchemaObject parent, String name) { 24 super(parent, name); 25 } 26 27 public void setDeprecatedSuggestion(String value) { 28 Object oldValue = fDeperecatedReplacement; 29 fDeperecatedReplacement = value; 30 getSchema().fireModelObjectChanged(this, P_DEP_REPLACEMENT, oldValue, fDeperecatedReplacement); 31 } 32 33 public String getDeprecatedSuggestion() { 34 return fDeperecatedReplacement; 35 } 36 37 public String getExtendedAttributes() { 38 if (fDeperecatedReplacement == null) 39 return null; 40 return " " + P_DEP_REPLACEMENT + "=\"" + fDeperecatedReplacement + "\" "; } 42 } 43 | Popular Tags |