Author: scabanovich
Date: 2007-07-23 08:43:34 -0400 (Mon, 23 Jul 2007)
New Revision: 2596
Modified:
trunk/common/plugins/org.jboss.tools.common.model/resources/meta/base.meta
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/impl/XModelImpl.java
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/project/ProjectHome.java
Log:
Obsolete *.pex extension usage removed
Modified: trunk/common/plugins/org.jboss.tools.common.model/resources/meta/base.meta
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model/resources/meta/base.meta 2007-07-23
12:42:46 UTC (rev 2595)
+++ trunk/common/plugins/org.jboss.tools.common.model/resources/meta/base.meta 2007-07-23
12:43:34 UTC (rev 2596)
@@ -449,7 +449,6 @@
ImplementationLoadingClass="org.jboss.tools.common.model.loaders.impl.RootLoaderImpl"
ImplementingClass="org.jboss.tools.common.model.impl.RootImpl"
name="Root">
<XChildrenEntities>
- <XChildEntity maxCount="1" name="Workspaces"
required="yes"/>
<XChildEntity maxCount="1" name="FileSystems"
required="yes"/>
</XChildrenEntities>
<XEntityRenderer>
@@ -482,7 +481,6 @@
ImplementationLoadingClass="org.jboss.tools.common.model.loaders.impl.RootLoaderImpl"
ImplementingClass="org.jboss.tools.common.model.impl.RootImpl"
name="RootDummy">
<XChildrenEntities>
- <XChildEntity maxCount="1" name="Workspaces"
required="yes"/>
<XChildEntity maxCount="1" name="SharableXStudio"
required="yes"/>
</XChildrenEntities>
<XEntityRenderer>
Modified:
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/impl/XModelImpl.java
===================================================================
---
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/impl/XModelImpl.java 2007-07-23
12:42:46 UTC (rev 2595)
+++
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/impl/XModelImpl.java 2007-07-23
12:43:34 UTC (rev 2596)
@@ -243,7 +243,7 @@
return null;
}
try {
- Class c = ent.getImplementingClass();
+ Class<?> c = ent.getImplementingClass();
XModelObjectImpl me = (XModelObjectImpl)c.newInstance();
me.setModel(this);
me.setEntityName_0(entity);
@@ -380,11 +380,7 @@
if(classloader.isUsed()) classloader = new XModelClassLoader(this);
classloader.validate();
fireStructureChanged(getRoot(), 3, null);
- if(!isDummy() &&
"true".equals(getProperties().getProperty("design"))) {
- OpenedProjectsImpl p =
(OpenedProjectsImpl)getRoot().getChildByPath("Workspaces");
- p.last(XModelConstants.getWorkspace(this) + "/" +
XModelConstants.getProjectPrefix(this) + "workspace.pex");
- if(p.isModified()) save();
- }
+
///Project Watcher
if(!isDummy()) loadWatcher();
}
@@ -568,11 +564,11 @@
}
}
- public List getTreeListeners() {
+ public List<XModelTreeListener> getTreeListeners() {
return Collections.unmodifiableList(this.treeListeners);
}
- public Map getManagerMap() {
+ public Map<String,Object> getManagerMap() {
return Collections.unmodifiableMap(managers);
}
}
Modified:
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/project/ProjectHome.java
===================================================================
---
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/project/ProjectHome.java 2007-07-23
12:42:46 UTC (rev 2595)
+++
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/project/ProjectHome.java 2007-07-23
12:43:34 UTC (rev 2596)
@@ -35,8 +35,8 @@
File f = new File(location + "/" + IModelNature.PROJECT_TEMP);
File ep = new File(location + "/" + IModelNature.PROJECT_FILE);
if(ep.isFile()) {
- // to remove .struts file if workspace.pex is not found
- if(f.isFile()) checkOldStrutsAndPexFile(location, f);
+ // to remove .struts file
+ if(f.isFile()) f.delete();
return getLocationFrom_strutsstudio_File(location, ep);
}
if(f.isFile()) return getLocationFrom_struts_File(location, f);
@@ -49,13 +49,6 @@
return q;
}
- private void checkOldStrutsAndPexFile(String location, File s) {
- String path = XModelObjectLoaderUtil.getCDATA(XMLUtil.getElement(s));
- String q = (path.startsWith("./")) ? location + path.substring(1) : path;
- File pex = new File(q + "/workspace.pex");
- if(!pex.exists()) s.delete();
- }
-
private String getLocationFrom_struts_File(String location, File s) {
String path = XModelObjectLoaderUtil.getCDATA(XMLUtil.getElement(s));
String q = (path.equals(".")) ? location : (path.startsWith("./"))
? location + path.substring(1) : path;