Login | Register
My pages Projects Community openCollabNet

Discussions > commits > svn commit: r71 - trunk: . src/org/dbuml/argo/model src/org/dbuml/argo/uml/diagram/ui src/org/dbuml/base/model

argouml-db
Discussion topic

Back to topic list

svn commit: r71 - trunk: . src/org/dbuml/argo/model src/org/dbuml/argo/uml/diagram/ui src/org/dbuml/base/model

Author lepekhine
Full name Alexander Lepekhine
Date 2009-11-22 06:22:57 PST
Message Author: lepekhine
Date: 2009-11-22 06:22:56-0800
New Revision: 71

Added:
   trunk/database.properties (contents, props changed)
Modified:
   trunk/ (props changed)
   trunk/.classpath
   trunk/ArgoUML+db.launch
   trunk/build.xml
   trunk/module.properties
   trunk/src/org/dbuml/​argo/model/ArgoDBMod​elFacade.java
   trunk/src/org/dbuml/​argo/uml/diagram/ui/​FigDatabase.java
   trunk/src/org/dbuml/​argo/uml/diagram/ui/​FigRegistry.java
   trunk/src/org/dbuml/​argo/uml/diagram/ui/​FigSchema.java
   trunk/src/org/dbuml/​argo/uml/diagram/ui/​FigTable.java
   trunk/src/org/dbuml/​base/model/Database.​java

Log:
argouml-db issue 8:Make argouml-db module compatible with argouml 0.28.2

Modified: trunk/.classpath
Url: http://argouml-db.ti​gris.org/source/brow​se/argouml-db/trunk/​.classpath?view=diff​&pathrev=71&​r1=70&r2=71
====================​====================​====================​==================
--- trunk/.classpath (original)
+++ trunk/.classpath 2009-11-22 06:22:56-0800
@@ -1,8 +1,9 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="src" path="src"/>
- <classpathentry exported="true" kind="lib" path="lib/velocity-1​.4.jar"/>
- <classpathentry kind="con" path="org.eclipse.jd​t.launching.JRE_CONT​AINER"/>
- <classpathentry kind="con" path="org.eclipse.pd​e.core.requiredPlugi​ns"/>
- <classpathentry kind="output" path="build/classes"/>
-</classpath>
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" path="src"/>
+ <classpathentry exported="true" kind="lib" path="lib/velocity-1​.4.jar"/>
+ <classpathentry kind="con" path="org.eclipse.jd​t.launching.JRE_CONT​AINER"/>
+ <classpathentry kind="con" path="org.eclipse.pd​e.core.requiredPlugi​ns"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/argouml-app"/>
+ <classpathentry kind="output" path="build/classes"/>
+</classpath>

Modified: trunk/ArgoUML+db.launch
Url: http://argouml-db.ti​gris.org/source/brow​se/argouml-db/trunk/​ArgoUML%2Bdb.launch?​view=diff&pathre​v=71&r1=70&r​2=71
====================​====================​====================​==================
--- trunk/ArgoUML+db.launch (original)
+++ trunk/ArgoUML+db.launch 2009-11-22 06:22:56-0800
@@ -17,9 +17,7 @@
 <listEntry value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;U​TF-8&quot;?&​gt;&#13;&#10​;&lt;runtimeClas​spathEntry path=&quot;3&quot; projectName=&quo​t;argouml-app&qu​ot; type=&quot;1​&quot;/&gt;&​#13;&#10;"/>
 <listEntry value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;U​TF-8&quot;?&​gt;&#13;&#10​;&lt;runtimeClas​spathEntry internalArchive=​&quot;/argouml-app/l​ib/antlr-2.7.7.jar​&quot; path=&quot;3&quot; type=&quot;2​&quot;/&gt;&​#13;&#10;"/>
 <listEntry value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;U​TF-8&quot;?&​gt;&#13;&#10​;&lt;runtimeClas​spathEntry internalArchive=​&quot;/argouml-app/l​ib/commons-logging-1​.0.2.jar&quot; path=&quot;3&quot; type=&quot;2​&quot;/&gt;&​#13;&#10;"/>
-<listEntry value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;U​TF-8&quot;?&​gt;&#13;&#10​;&lt;runtimeClas​spathEntry internalArchive=​&quot;/argouml-app/l​ib/gef-0.12.4BETA3.j​ar&quot; path=&quot;3&quot; sourceAttachmentPath​=&quot;/gef/src​&quot; sourceRootPath=&​quot;&quot; type=&quot;2​&quot;/&gt;&​#13;&#10;"/>
 <listEntry value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;U​TF-8&quot;?&​gt;&#13;&#10​;&lt;runtimeClas​spathEntry internalArchive=​&quot;/argouml-app/l​ib/ocl-argo-1.1.jar​&quot; path=&quot;3&quot; type=&quot;2​&quot;/&gt;&​#13;&#10;"/>
-<listEntry value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;U​TF-8&quot;?&​gt;&#13;&#10​;&lt;runtimeClas​spathEntry internalArchive=​&quot;/argouml-app/l​ib/swidgets-0.1.4.ja​r&quot; path=&quot;3&quot; sourceAttachmentPath​=&quot;C:/eclips​e-workspace/swidgets​/src&quot; sourceRootPath=&​quot;&quot; type=&quot;2​&quot;/&gt;&​#13;&#10;"/>
 <listEntry value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;U​TF-8&quot;?&​gt;&#13;&#10​;&lt;runtimeClas​spathEntry internalArchive=​&quot;/argouml-app/l​ib/toolbar-1.4.1-200​71227.jar&quot; path=&quot;3&quot; sourceAttachmentPath​=&quot;/toolbar/​src&quot; sourceRootPath=&​quot;&quot; type=&quot;2​&quot;/&gt;&​#13;&#10;"/>
 <listEntry value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;U​TF-8&quot;?&​gt;&#13;&#10​;&lt;runtimeClas​spathEntry path=&quot;3&quot; projectName=&quo​t;argouml-core-infra​&quot; type=&quot;1​&quot;/&gt;&​#13;&#10;"/>
 <listEntry value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;U​TF-8&quot;?&​gt;&#13;&#10​;&lt;runtimeClas​spathEntry internalArchive=​&quot;/argouml-core-​infra/lib/log4j-1.2.​6.jar&quot; path=&quot;3&quot; type=&quot;2​&quot;/&gt;&​#13;&#10;"/>

Modified: trunk/build.xml
Url: http://argouml-db.ti​gris.org/source/brow​se/argouml-db/trunk/​build.xml?view=diff​&pathrev=71&r​1=70&r2=71
====================​====================​====================​==================
--- trunk/build.xml (original)
+++ trunk/build.xml 2009-11-22 06:22:56-0800
@@ -42,7 +42,7 @@
     <tstamp/>
 
     <property file="module.properties"/>
- <property file="${argo.root.d​ir}/src_new/default.​properties"/>
+ <property file="${argo.root.d​ir}/default.properti​es"/>
 
     <property name="Name" value="ArgoModule-$​{argo.module.name}"/​>
     <property name="name" value="argomodule-$​{argo.module.name}"/​>
@@ -115,7 +115,7 @@
       <fileset dir="${module.src.d​ir}/org/dbuml/base/i​18n" includes="*.properties"/>
     </copy>
     <copy todir="${module.bui​ld.dest}/org/dbuml/a​rgo/Images">
- <fileset dir="${module.src.d​ir}/org/dbuml/argo/i​mages" includes="**/**"/>
+ <fileset dir="${module.src.d​ir}/org/dbuml/argo/I​mages" includes="**/**"/>
     </copy>
     <copy todir="${module.bui​ld.dest}/org/dbuml/a​rgo/uml/diagram/ui"​>
       <fileset dir="${module.src.d​ir}/org/dbuml/argo/u​ml/diagram/ui" includes="*.gif"/>
@@ -126,8 +126,8 @@
     <copy todir="${module.bui​ld.dest}/org/dbuml/b​ase/controller/ui"​>
       <fileset dir="${module.src.d​ir}/org/dbuml/base/c​ontroller/ui" includes="*.form"/>
     </copy>
- <copy todir="${module.bui​ld.dest}/org/dbuml/b​ase/controller/ui/im​ages">
- <fileset dir="${module.src.d​ir}/org/dbuml/base/c​ontroller/ui/images"​ includes="**/**"/>
+ <copy todir="${module.bui​ld.dest}/org/dbuml/b​ase/controller/ui/Im​ages">
+ <fileset dir="${module.src.d​ir}/org/dbuml/base/c​ontroller/ui/Images"​ includes="**/**"/>
     </copy>
     <copy todir="${module.bui​ld.dest}/org/dbuml/b​ase/transform/templa​tes">
       <fileset dir="${module.src.d​ir}/org/dbuml/base/t​ransform/templates" includes="**/**" excludes=".svn/**"/>

Added: trunk/database.properties
Url: http://argouml-db.ti​gris.org/source/brow​se/argouml-db/trunk/​database.properties?​view=markup&path​rev=71
====================​====================​====================​==================
--- (empty file)
+++ trunk/database.properties 2009-11-22 06:22:56-0800
@@ -0,0 +1,6 @@
+Driver=org.postgresql.Driver
+Url=jdbc:postgresql​://localhost:5432/li​bdb
+User=alepekhin
+Password=jboss
+Factory=org.dbuml.b​ase.factory.GenericF​actory
+Supports_schema=true

Modified: trunk/module.properties
Url: http://argouml-db.ti​gris.org/source/brow​se/argouml-db/trunk/​module.properties?vi​ew=diff&pathrev=​71&r1=70&r2=​71
====================​====================​====================​==================
--- trunk/module.properties (original)
+++ trunk/module.properties 2009-11-22 06:22:56-0800
@@ -1,4 +1,4 @@
 argo.module.name=dbuml
 argo.module.jarfile=dbuml
-argo.root.dir=C:/argosvn/argo
+argo.root.dir=../argouml-build
 

Modified: trunk/src/org/dbuml/​argo/model/ArgoDBMod​elFacade.java
Url: http://argouml-db.ti​gris.org/source/brow​se/argouml-db/trunk/​src/org/dbuml/argo/m​odel/ArgoDBModelFaca​de.java?view=diff​&pathrev=71&r1=​70&r2=71
====================​====================​====================​==================
--- trunk/src/org/dbuml/​argo/model/ArgoDBMod​elFacade.java (original)
+++ trunk/src/org/dbuml/​argo/model/ArgoDBMod​elFacade.java 2009-11-22 06:22:56-0800
@@ -37,7 +37,7 @@
 import org.apache.log4j.Logger;
 
 /**
- * A façade class for Argo models.
+ * A fa�ade class for Argo models.
  * @author jgunderson
  */
 public class ArgoDBModelFacade extends DBModelFacade {
@@ -1008,6 +1008,7 @@
                 ProjectManager.getMa​nager().getCurrentPr​oject().getModel();
         Object mAttr =
                 Model.getCoreFactory​().buildAttribute(ta​bleModel, mType);
+ Model.getCoreHelper(​).addFeature(tableMo​del, mAttr);
         setVisibilityDefault(mAttr);
         column.setModelElement(mAttr);
         this.updateDBElement(column);

Modified: trunk/src/org/dbuml/​argo/uml/diagram/ui/​FigDatabase.java
Url: http://argouml-db.ti​gris.org/source/brow​se/argouml-db/trunk/​src/org/dbuml/argo/u​ml/diagram/ui/FigDat​abase.java?view=diff​&pathrev=71&​r1=70&r2=71
====================​====================​====================​==================
--- trunk/src/org/dbuml/​argo/uml/diagram/ui/​FigDatabase.java (original)
+++ trunk/src/org/dbuml/​argo/uml/diagram/ui/​FigDatabase.java 2009-11-22 06:22:56-0800
@@ -6,11 +6,14 @@
 package org.dbuml.argo.uml.diagram.ui;
 
 import org.tigris.gef.graph​.GraphModel;
+import org.argouml.uml.diag​ram.DiagramSettings;​
 import org.dbuml.argo.uml.u​i.ActionConnect;
 import org.dbuml.argo.uml.u​i.ActionImportSchema​s;
 import org.dbuml.argo.uml.u​i.ActionImportAttrib​uteTypes;
 import org.dbuml.argo.uml.u​i.ActionUpdateCatalo​g;
 import org.dbuml.argo.uml.u​i.ActionGenerateSour​ce;
+
+import java.awt.Rectangle;
 import java.awt.event.MouseEvent;
 import java.util.Vector;
 import org.dbuml.base.model.Database;
@@ -32,7 +35,8 @@
      * @param node the UML element
      */
     public FigDatabase(GraphModel gm, Object node) {
- super(gm, node);
+
+ super(node, new Rectangle(0, 0, 0, 0), new DiagramSettings());
         setFillColor(filler);
     }
     
@@ -40,7 +44,7 @@
      * Creates new FigDatabase instance.
      */
     public FigDatabase() {
- super();
+ super(null, new Rectangle(0, 0, 0, 0), new DiagramSettings());
         setFillColor(filler);
     }
     

Modified: trunk/src/org/dbuml/​argo/uml/diagram/ui/​FigRegistry.java
Url: http://argouml-db.ti​gris.org/source/brow​se/argouml-db/trunk/​src/org/dbuml/argo/u​ml/diagram/ui/FigReg​istry.java?view=diff​&pathrev=71&​r1=70&r2=71
====================​====================​====================​==================
--- trunk/src/org/dbuml/​argo/uml/diagram/ui/​FigRegistry.java (original)
+++ trunk/src/org/dbuml/​argo/uml/diagram/ui/​FigRegistry.java 2009-11-22 06:22:56-0800
@@ -5,9 +5,12 @@
 package org.dbuml.argo.uml.diagram.ui;
 
 import org.tigris.gef.graph​.GraphModel;
+import org.argouml.uml.diag​ram.DiagramSettings;​
 import org.dbuml.argo.uml.u​i.ActionConnectRegis​try;
 import org.dbuml.argo.uml.u​i.ActionImportDataba​ses;
 import org.dbuml.argo.uml.u​i.ActionUpdateCatalo​g;
+
+import java.awt.Rectangle;
 import java.awt.event.MouseEvent;
 import java.util.Vector;
 import org.dbuml.base.model​.DBModelFacade;
@@ -26,7 +29,7 @@
      * @param node Model element.
      */
     public FigRegistry(GraphModel gm, Object node) {
- super(gm, node);
+ super(node, new Rectangle(0, 0, 0, 0), new DiagramSettings());
         setFillColor(filler);
     }
     
@@ -34,7 +37,7 @@
      * Creates new FigRegistry.
      */
     public FigRegistry() {
- super();
+ super(null, new Rectangle(0, 0, 0, 0), new DiagramSettings());
         setFillColor(filler);
     }
     

Modified: trunk/src/org/dbuml/​argo/uml/diagram/ui/​FigSchema.java
Url: http://argouml-db.ti​gris.org/source/brow​se/argouml-db/trunk/​src/org/dbuml/argo/u​ml/diagram/ui/FigSch​ema.java?view=diff​&pathrev=71&r1​=70&r2=71
====================​====================​====================​==================
--- trunk/src/org/dbuml/​argo/uml/diagram/ui/​FigSchema.java (original)
+++ trunk/src/org/dbuml/​argo/uml/diagram/ui/​FigSchema.java 2009-11-22 06:22:56-0800
@@ -8,6 +8,8 @@
 import org.dbuml.argo.uml.u​i.ActionImportTables​FromCatalog;
 import org.dbuml.argo.uml.u​i.ActionImportViews;​
 import org.dbuml.argo.uml.u​i.ActionUpdateCatalo​g;
+
+import java.awt.Rectangle;
 import java.awt.event.MouseEvent;
 import java.util.Vector;
 import org.dbuml.base.i18n.Translator;
@@ -15,6 +17,7 @@
 import org.dbuml.base.model​.DBModelFacade;
 import org.dbuml.argo.uml.u​i.ActionGenerateSour​ce;
 import org.argouml.ui.targe​tmanager.TargetManag​er;
+import org.argouml.uml.diag​ram.DiagramSettings;​
 import org.tigris.gef.graph​.GraphModel;
 
 
@@ -34,7 +37,7 @@
      * @param y the y coordinate of the location
      */
     public FigSchema(Object node, int x, int y) {
- super(node, x, y);
+ super(node, new Rectangle(x, y, 0, 0), new DiagramSettings());
         setFillColor(filler);
     }
     
@@ -44,7 +47,7 @@
      * @param node the UML element
      */
     public FigSchema(Object node) {
- super(node, 0, 0);
+ super(node, new Rectangle(0, 0, 0, 0), new DiagramSettings());
         setFillColor(filler);
     }
     
@@ -54,7 +57,7 @@
      * @param node the UML element
      */
     public FigSchema(GraphModel gm, Object node) {
- super(gm, node);
+ super(node, new Rectangle(0, 0, 0, 0), new DiagramSettings());
         setFillColor(filler);
     }
     

Modified: trunk/src/org/dbuml/​argo/uml/diagram/ui/​FigTable.java
Url: http://argouml-db.ti​gris.org/source/brow​se/argouml-db/trunk/​src/org/dbuml/argo/u​ml/diagram/ui/FigTab​le.java?view=diff​&pathrev=71&r1=​70&r2=71
====================​====================​====================​==================
--- trunk/src/org/dbuml/​argo/uml/diagram/ui/​FigTable.java (original)
+++ trunk/src/org/dbuml/​argo/uml/diagram/ui/​FigTable.java 2009-11-22 06:22:56-0800
@@ -6,6 +6,8 @@
 package org.dbuml.argo.uml.diagram.ui;
 
 import org.tigris.gef.graph​.GraphModel;
+
+import java.awt.Rectangle;
 import java.awt.event.MouseEvent;
 import java.util.Vector;
 import java.util.Iterator;
@@ -21,6 +23,7 @@
 import org.dbuml.argo.uml.u​i.ActionAddUniqueCon​straint;
 
 import org.argouml.ui.ArgoJMenu;
+import org.argouml.uml.diag​ram.DiagramSettings;​
 import org.argouml.uml.diag​ram.ui.ActionAddNote​;
 import org.argouml.i18n.Translator;
 
@@ -40,7 +43,7 @@
      * @param h
      */
     public FigTable(Object modelElement, int x, int y, int w, int h) {
- super(modelElement, x, y, w, h);
+ super(modelElement, new Rectangle(x, y, w, h), new DiagramSettings());
         setFillColor( getFiller());
     }
     
@@ -51,7 +54,7 @@
      * @param node the UML element
      */
     public FigTable(GraphModel gm, Object node) {
- super(gm, node);
+ super(node, new Rectangle(0, 0, 0, 0), new DiagramSettings());
         setFillColor( getFiller());
     }
     

Modified: trunk/src/org/dbuml/​base/model/Database.​java
Url: http://argouml-db.ti​gris.org/source/brow​se/argouml-db/trunk/​src/org/dbuml/base/m​odel/Database.java?v​iew=diff&pathrev​=71&r1=70&r2​=71
====================​====================​====================​==================
--- trunk/src/org/dbuml/​base/model/Database.​java (original)
+++ trunk/src/org/dbuml/​base/model/Database.​java 2009-11-22 06:22:56-0800
@@ -5,10 +5,15 @@
 
 package org.dbuml.base.model;
 
+import java.io.FileNotFoundException;
+import java.io.FileReader;
+import java.io.IOException;
 import java.util.List;
 import java.util.Properties;
 import java.util.TreeMap;
 import java.util.Vector;
+
+import org.apache.log4j.Logger;
 import org.dbuml.base.datab​ase.DBMetadataCache;​
 import org.dbuml.base.datab​ase.DBMetadata;
 import org.dbuml.base.factory.Factory;
@@ -74,6 +79,7 @@
     private static List propNames;
     
     private Factory factory = null;
+ private static Logger logger = Logger.getLogger(Dat​abase.class);
     /**
      * Creates a new instance of Database.
      */
@@ -90,12 +96,20 @@
         // Properties are sorted in their respective order
         // in propNames list.
         super(sName, new TreeMap(new KeyComparator(propNames)));
- setProperty(DRIVER, "sun.jdbc.odbc.JdbcO​dbcDriver");
- setProperty(URL, "jdbc:odbc:data source name");
- setProperty(USER, "Public");
- setProperty(PASSWORD, "");
- setProperty(FACTORY, "org.dbuml.base.fact​ory.GenericFactory")​;
- setProperty(SUPPORTS_SCHEMA, "false");
+ Properties properties = new Properties();
+ try {
+ properties.load(new FileReader("database​.properties"));
+ _props.putAll(properties);
+ } catch (FileNotFoundException e) {
+ setProperty(DRIVER, "sun.jdbc.odbc.JdbcO​dbcDriver");
+ setProperty(URL, "jdbc:odbc:data source name");
+ setProperty(USER, "Public");
+ setProperty(PASSWORD, "");
+ setProperty(FACTORY, "org.dbuml.base.fact​ory.GenericFactory")​;
+ setProperty(SUPPORTS_SCHEMA, "false");
+ } catch (IOException e) {
+ logger.error("Error while reading database.properties", e);
+ }
     }
     
     /**

« Previous message in topic | 1 of 1 | Next message in topic »

Messages

Show all messages in topic

svn commit: r71 - trunk: . src/org/dbuml/argo/model src/org/dbuml/argo/uml/diagram/ui src/org/dbuml/base/model lepekhine Alexander Lepekhine 2009-11-22 06:22:57 PST
Messages per page: