diff options
author | pfullbright | 2009-04-20 21:48:46 +0000 |
---|---|---|
committer | pfullbright | 2009-04-20 21:48:46 +0000 |
commit | 1226d185a3a96490a82f51d1613c7aa778d06a48 (patch) | |
tree | fa4e25d7f86e29d1f0c1c598715a7b72cbff1ca3 | |
parent | 29ec9560df6fe5961f7bbfb678d3d0290b037c95 (diff) | |
download | webtools.dali-1226d185a3a96490a82f51d1613c7aa778d06a48.tar.gz webtools.dali-1226d185a3a96490a82f51d1613c7aa778d06a48.tar.xz webtools.dali-1226d185a3a96490a82f51d1613c7aa778d06a48.zip |
cosmetic
3 files changed, 29 insertions, 24 deletions
diff --git a/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/context/persistence/MappingFileRef.java b/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/context/persistence/MappingFileRef.java index bd5120bbea..09a43c2cf4 100644 --- a/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/context/persistence/MappingFileRef.java +++ b/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/context/persistence/MappingFileRef.java @@ -100,5 +100,4 @@ public interface MappingFileRef * the specified text offset. */ boolean containsOffset(int textOffset); - } diff --git a/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/persistence/AbstractMappingFileRef.java b/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/persistence/AbstractMappingFileRef.java index f1683edb14..2efbbf0bc3 100644 --- a/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/persistence/AbstractMappingFileRef.java +++ b/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/persistence/AbstractMappingFileRef.java @@ -10,7 +10,6 @@ package org.eclipse.jpt.core.internal.context.persistence; import java.util.List; - import org.eclipse.core.resources.IFile; import org.eclipse.core.runtime.content.IContentType; import org.eclipse.jpt.core.JpaStructureNode; @@ -33,7 +32,6 @@ public abstract class AbstractMappingFileRef extends AbstractXmlContextNode implements MappingFileRef { - protected String fileName; protected MappingFile mappingFile; diff --git a/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/persistence/GenericMappingFileRef.java b/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/persistence/GenericMappingFileRef.java index 1e22617111..3d4d32ceb7 100644 --- a/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/persistence/GenericMappingFileRef.java +++ b/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/persistence/GenericMappingFileRef.java @@ -19,29 +19,16 @@ public class GenericMappingFileRef protected XmlMappingFileRef xmlMappingFileRef; - // ********** construction/initialization ********** + // **************** construction/initialization **************************** public GenericMappingFileRef(PersistenceUnit parent, XmlMappingFileRef xmlMappingFileRef) { super(parent, xmlMappingFileRef.getFileName()); this.xmlMappingFileRef = xmlMappingFileRef; } - - public boolean isImplied() { - return false; - } - - public TextRange getSelectionTextRange() { - return this.xmlMappingFileRef.getSelectionTextRange(); - } - public TextRange getValidationTextRange() { - return this.xmlMappingFileRef.getValidationTextRange(); - } - - public boolean containsOffset(int textOffset) { - return this.xmlMappingFileRef.containsOffset(textOffset); - } - + + // **************** file name ********************************************** + public void setFileName(String newFileName) { String old = this.fileName; this.fileName = newFileName; @@ -55,14 +42,35 @@ public class GenericMappingFileRef this.firePropertyChanged(FILE_NAME_PROPERTY, old, newFileName); } - protected String getResourceFileName() { - return this.xmlMappingFileRef.getFileName(); - } + + // **************** MappingFileRef impl ************************************ public void update(XmlMappingFileRef mappingFileRef) { this.xmlMappingFileRef = mappingFileRef; this.setFileName_(this.getResourceFileName()); super.update(); } - + + protected String getResourceFileName() { + return this.xmlMappingFileRef.getFileName(); + } + + public boolean isImplied() { + return false; + } + + public boolean containsOffset(int textOffset) { + return this.xmlMappingFileRef.containsOffset(textOffset); + } + + + // **************** JpaStructureNode impl ********************************** + + public TextRange getSelectionTextRange() { + return this.xmlMappingFileRef.getSelectionTextRange(); + } + + public TextRange getValidationTextRange() { + return this.xmlMappingFileRef.getValidationTextRange(); + } } |