Seco Eclipse Plugin Released

5 views
Skip to first unread message

Konstantin vandev

unread,
Oct 21, 2010, 11:34:53 AM10/21/10
to Seco
A first version of the eclipse plugin for Seco is released For more
information read: http://code.google.com/p/seco/wiki/EclipsePlugin

Borislav Iordanov

unread,
Oct 21, 2010, 2:53:14 PM10/21/10
to scr...@googlegroups.com
It would be nice to automatically sync up Seco's runtime contexts with
Eclipse projects. Furthermore, it would also be cool to associate a
single Seco runtime context with several Eclipse projects. But perhaps
that should be a separate Seco future where nested contexts can be
build out of simpler ones :)

Boris

> --
> You received this message because you are subscribed to the Google Groups "Seco" group.
> To post to this group, send email to scr...@googlegroups.com.
> To unsubscribe from this group, send email to scriba+un...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/scriba?hl=en.
>
>

--
http://www.kobrix.com - HGDB graph database, Java Scripting IDE, NLP
http://kobrix.blogspot.com - news and rants

"Frozen brains tell no tales."

-- Buckethead

Konstantin vandev

unread,
Oct 22, 2010, 7:21:43 AM10/22/10
to Seco
Yes, we'll consider adding nested context to Seco. Until then you
should use the following code directly in the notebook:

import org.eclipse.jdt.core.*;
import org.eclipse.jdt.internal.core.*;
jp =
JavaModelManager.getJavaModelManager().getJavaModel().getJavaProject("seco");
pr = jp.getCorrespondingResource();
cp = jp.getRawClasspath();
seco_cp =
ThisNiche.getTopContext().getRuntimeContext().getClassPath();
for (int i = 0; i < cp.length; i ++)
{
if (cp[i].getEntryKind() == IClasspathEntry.CPE_LIBRARY &&
cp[i].getContentKind() == IPackageFragmentRoot.K_BINARY)
{
f = new File("" + pr.getStore().getChild(cp[i].getPath()));
seco_cp.add(new seco.rtenv.ClassPathEntry(f));
}
}

This will add all the lib jars from project named "seco" in the top
runtime context.

Konstantin

On Oct 21, 9:53 pm, Borislav Iordanov <borislav.iorda...@gmail.com>
wrote:

Borislav Iordanov

unread,
Oct 24, 2010, 10:14:04 PM10/24/10
to scr...@googlegroups.com
And what about the compiled classes of the project itself? Are they also added?

Boris

Konstantin vandev

unread,
Oct 25, 2010, 4:23:59 AM10/25/10
to Seco
Simply add the following code in the loop:

else if (src.getEntryKind() == IClasspathEntry.CPE_SOURCE &&
src.getContentKind() == IPackageFragmentRoot.K_SOURCE)
{
//when cp's outputLocation is null, the project's one is used
f = (cp[i].getOutputLocation() != null) ?
new File("" +
pr.getStore().getChild(cp[i].getOutputLocation())) :
new File("" +
pr.getStore().getChild(jp.getOutputLocation()));
seco_cp.add(new seco.rtenv.ClassPathEntry(f));
}


On Oct 25, 5:14 am, Borislav Iordanov <borislav.iorda...@gmail.com>
wrote:
Reply all
Reply to author
Forward
0 new messages