click-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From take...@apache.org
Subject svn commit: r796151 - in /incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne: ./ META-INF/ cayenne/ src/org/apache/click/eclipse/cayenne/ src/org/apache/click/eclipse/cayenne/wizard/
Date Tue, 21 Jul 2009 06:10:49 GMT
Author: takezoe
Date: Tue Jul 21 06:10:48 2009
New Revision: 796151

URL: http://svn.apache.org/viewvc?rev=796151&view=rev
Log:
Upgrade Cayenne to 3.0M6.

Added:
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/CayenneModeler.jar
  (with props)
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/ashwood-2.0.jar
  (with props)
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/cayenne-server-3.0M6.jar
  (with props)
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/commons-collections-3.1.jar
  (with props)
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/commons-logging-1.1.jar
  (with props)
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/CayenneClasspathContainerInitializer.java
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/CayenneClasspathContainerPage.java
Removed:
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/cayenne-modeler.jar
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/cayenne-nodeps.jar
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/cayenne.jar
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/commons-dbcp-1.2.1.jar
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/commons-pool-1.2.jar
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/forms-1.0.3.jar
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/hsqldb-1.8.0.2.jar
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/looks-1.3.1.jar
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/ognl-2.6.7.jar
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/scope-bin-1.0.1.jar
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/CayenneClasspathVariableInitializer.java
Modified:
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/META-INF/MANIFEST.MF
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/plugin.xml
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/CayennePlugin.java
    incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/wizard/cayenne.xml

Modified: incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/META-INF/MANIFEST.MF
URL: http://svn.apache.org/viewvc/incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/META-INF/MANIFEST.MF?rev=796151&r1=796150&r2=796151&view=diff
==============================================================================
--- incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/META-INF/MANIFEST.MF
(original)
+++ incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/META-INF/MANIFEST.MF
Tue Jul 21 06:10:48 2009
@@ -2,14 +2,15 @@
 Bundle-ManifestVersion: 2
 Bundle-Name: Cayenne Plug-In
 Bundle-SymbolicName: org.apache.click.eclipse.cayenne;singleton:=true
-Bundle-Version: 2.1.0
+Bundle-Version: 3.0.0
 Bundle-Activator: org.apache.click.eclipse.cayenne.CayennePlugin
 Require-Bundle: org.eclipse.ui,
  org.eclipse.core.runtime,
  org.eclipse.jdt.launching,
  org.eclipse.debug.core,
  org.eclipse.ui.ide,
- org.eclipse.jdt.core
+ org.eclipse.jdt.core,
+ org.eclipse.jdt.ui;bundle-version="3.5.0"
 Eclipse-LazyStart: true
 Bundle-ClassPath: .
 Export-Package: org.apache.click.eclipse.cayenne,

Added: incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/CayenneModeler.jar
URL: http://svn.apache.org/viewvc/incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/CayenneModeler.jar?rev=796151&view=auto
==============================================================================
Binary file - no diff available.

Propchange: incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/CayenneModeler.jar
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/ashwood-2.0.jar
URL: http://svn.apache.org/viewvc/incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/ashwood-2.0.jar?rev=796151&view=auto
==============================================================================
Binary file - no diff available.

Propchange: incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/ashwood-2.0.jar
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/cayenne-server-3.0M6.jar
URL: http://svn.apache.org/viewvc/incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/cayenne-server-3.0M6.jar?rev=796151&view=auto
==============================================================================
Binary file - no diff available.

Propchange: incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/cayenne-server-3.0M6.jar
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/commons-collections-3.1.jar
URL: http://svn.apache.org/viewvc/incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/commons-collections-3.1.jar?rev=796151&view=auto
==============================================================================
Binary file - no diff available.

Propchange: incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/commons-collections-3.1.jar
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/commons-logging-1.1.jar
URL: http://svn.apache.org/viewvc/incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/commons-logging-1.1.jar?rev=796151&view=auto
==============================================================================
Binary file - no diff available.

Propchange: incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/cayenne/commons-logging-1.1.jar
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Modified: incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/plugin.xml
URL: http://svn.apache.org/viewvc/incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/plugin.xml?rev=796151&r1=796150&r2=796151&view=diff
==============================================================================
--- incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/plugin.xml (original)
+++ incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/plugin.xml Tue Jul
21 06:10:48 2009
@@ -44,11 +44,25 @@
       </wizard>
    </extension>
    <extension
+         point="org.eclipse.jdt.core.classpathContainerInitializer">
+      <classpathContainerInitializer
+         class="org.apache.click.eclipse.cayenne.CayenneClasspathContainerInitializer"
+         id="org.apache.click.eclipse.cayenne.CAYENNE_LIBS"/>
+   </extension>
+   <extension
+         point="org.eclipse.jdt.ui.classpathContainerPage">
+      <classpathContainerPath 
+         class="org.apache.click.eclipse.cayenne.CayenneClasspathContainerPage"
+         id="org.apache.click.eclipse.cayenne.CAYENNE_LIBS"
+         name="Cayennne Libraries"/>
+   </extension>
+   <!--
+   <extension
          point="org.eclipse.jdt.core.classpathVariableInitializer">
       <classpathVariableInitializer
             class="org.apache.click.eclipse.cayenne.CayenneClasspathVariableInitializer"
             variable="org.apache.click.eclipse.cayenne.classpathVariableInitializer">
       </classpathVariableInitializer>
    </extension>
-
+   -->
 </plugin>

Added: incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/CayenneClasspathContainerInitializer.java
URL: http://svn.apache.org/viewvc/incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/CayenneClasspathContainerInitializer.java?rev=796151&view=auto
==============================================================================
--- incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/CayenneClasspathContainerInitializer.java
(added)
+++ incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/CayenneClasspathContainerInitializer.java
Tue Jul 21 06:10:48 2009
@@ -0,0 +1,87 @@
+package org.apache.click.eclipse.cayenne;
+
+import java.io.File;
+import java.io.IOException;
+import java.net.URL;
+
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.FileLocator;
+import org.eclipse.core.runtime.IPath;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.jdt.core.ClasspathContainerInitializer;
+import org.eclipse.jdt.core.IClasspathContainer;
+import org.eclipse.jdt.core.IClasspathEntry;
+import org.eclipse.jdt.core.IJavaProject;
+import org.eclipse.jdt.core.JavaCore;
+import org.osgi.framework.Bundle;
+
+/**
+ * Provides classpath container <tt>CAYENNE_LIBS</tt>.
+ * 
+ * @author Naoki Takezoe
+ */
+public class CayenneClasspathContainerInitializer extends ClasspathContainerInitializer {
+	
+	public static final String CONTAINER_ID = "org.apache.click.eclipse.cayenne.CAYENNE_LIBS";
+	
+	public void initialize(final IPath containerPath, IJavaProject project) throws CoreException
{
+		
+		final IClasspathEntry[] entries = new IClasspathEntry[]{
+				getLibraryEntry("cayenne/cayenne-server-3.0M6.jar"),
+				getLibraryEntry("cayenne/ashwood-2.0.jar"),
+				getLibraryEntry("cayenne/commons-collections-3.1.jar"),
+				getLibraryEntry("cayenne/commons-logging-1.1.jar"),
+		};
+		
+		IClasspathContainer container = new IClasspathContainer() {
+			
+			public IPath getPath() {
+				return containerPath;
+			}
+			
+			public int getKind() {
+				return IClasspathContainer.K_APPLICATION;
+			}
+			
+			public String getDescription() {
+				return "Cayenne Libraries";
+			}
+			
+			public IClasspathEntry[] getClasspathEntries() {
+				return entries;
+			}
+		};
+		
+		JavaCore.setClasspathContainer(containerPath, 
+				new IJavaProject[]{project}, 
+				new IClasspathContainer[]{container}, 
+				null);
+	}
+	
+	private static IClasspathEntry getLibraryEntry(String path){
+		IPath bundleBase = getBundleLocation();
+		if(bundleBase != null){
+			IPath jarLocation = bundleBase.append(path);
+			return JavaCore.newLibraryEntry(jarLocation, null, null);
+		}
+		return null;
+	}
+
+	
+	private static IPath getBundleLocation(){
+		Bundle bundle = CayennePlugin.getDefault().getBundle();
+		if(bundle == null){
+			return null;
+		}
+		
+		URL local = null;
+		try {
+			local = FileLocator.toFileURL(bundle.getEntry("/"));
+		} catch(IOException ex){
+			return null;
+		}
+
+		String fullPath = new File(local.getPath()).getAbsolutePath();
+		return Path.fromOSString(fullPath);
+	}
+}

Added: incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/CayenneClasspathContainerPage.java
URL: http://svn.apache.org/viewvc/incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/CayenneClasspathContainerPage.java?rev=796151&view=auto
==============================================================================
--- incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/CayenneClasspathContainerPage.java
(added)
+++ incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/CayenneClasspathContainerPage.java
Tue Jul 21 06:10:48 2009
@@ -0,0 +1,45 @@
+package org.apache.click.eclipse.cayenne;
+
+import org.eclipse.core.runtime.Path;
+import org.eclipse.jdt.core.IClasspathEntry;
+import org.eclipse.jdt.core.JavaCore;
+import org.eclipse.jdt.ui.wizards.IClasspathContainerPage;
+import org.eclipse.jface.wizard.WizardPage;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.layout.GridLayout;
+import org.eclipse.swt.widgets.Composite;
+
+/**
+ * 
+ * @author Naoki Takezoe
+ */
+public class CayenneClasspathContainerPage extends WizardPage implements IClasspathContainerPage
{
+	
+	private IClasspathEntry containerEntryResult;
+	
+	public CayenneClasspathContainerPage() {
+		super("CayenneClasspathContainerPage");
+		setTitle("Cayenne Libraries");
+		setDescription("Add Cayenne libraries to classpath.");
+	}
+
+	public boolean finish() {
+		containerEntryResult = JavaCore.newContainerEntry(
+				new Path(CayenneClasspathContainerInitializer.CONTAINER_ID));
+		return true;
+	}
+
+	public IClasspathEntry getSelection() {
+		return containerEntryResult;
+	}
+
+	public void setSelection(IClasspathEntry entry) {
+	}
+
+	public void createControl(Composite parent) {
+		Composite composite = new Composite(parent, SWT.NULL);
+		composite.setLayout(new GridLayout());
+		setControl(composite);
+	}
+
+}

Modified: incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/CayennePlugin.java
URL: http://svn.apache.org/viewvc/incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/CayennePlugin.java?rev=796151&r1=796150&r2=796151&view=diff
==============================================================================
--- incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/CayennePlugin.java
(original)
+++ incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/CayennePlugin.java
Tue Jul 21 06:10:48 2009
@@ -89,15 +89,16 @@
 		}
 		File dir = CayennePlugin.getDefault().getStateLocation().toFile();
 		files = new File[]{
-				new File(dir, "cayenne.jar"),
-				new File(dir, "cayenne-modeler.jar"),
-				new File(dir, "commons-dbcp-1.2.1.jar"),
-				new File(dir, "commons-pool-1.2.jar"),
-				new File(dir, "forms-1.0.3.jar"),
-				new File(dir, "hsqldb-1.8.0.2.jar"),
-				new File(dir, "looks-1.3.1.jar"),
-				new File(dir, "ognl-2.6.7.jar"),
-				new File(dir, "scope-bin-1.0.1.jar"),
+//				new File(dir, "cayenne.jar"),
+//				new File(dir, "cayenne-modeler.jar"),
+//				new File(dir, "commons-dbcp-1.2.1.jar"),
+//				new File(dir, "commons-pool-1.2.jar"),
+//				new File(dir, "forms-1.0.3.jar"),
+//				new File(dir, "hsqldb-1.8.0.2.jar"),
+//				new File(dir, "looks-1.3.1.jar"),
+//				new File(dir, "ognl-2.6.7.jar"),
+//				new File(dir, "scope-bin-1.0.1.jar"),
+				new File(dir, "CayenneModeler.jar"),
 		};
 		return files;
 	}

Modified: incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/wizard/cayenne.xml
URL: http://svn.apache.org/viewvc/incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/wizard/cayenne.xml?rev=796151&r1=796150&r2=796151&view=diff
==============================================================================
--- incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/wizard/cayenne.xml
(original)
+++ incubator/click/trunk/tools/eclipse/org.apache.click.eclipse.cayenne/src/org/apache/click/eclipse/cayenne/wizard/cayenne.xml
Tue Jul 21 06:10:48 2009
@@ -1,3 +1,3 @@
 <?xml version="1.0" encoding="utf-8"?>
-<domains project-version="2.0">
+<domains project-version="3.0">
 </domains>



Mime
View raw message