I've used this DynamicRelationType in my project, but there is
something strange going on. Look at what I see in the neo shell:
$ ls
(me) --[INDEX_SERVICE]-- (1)
(me) --[MUSICBRAINZ]-- (4)
neo-sh (0)$ cd 4
neo-sh (4)$ ls
(me) --[ARTISTS]-- (5)
(me) --[MUSICBRAINZ]-- (0)
neo-sh (4)$ cd 5
neo-sh
I fixed that bug... there will be a new SNAPSHOT of neo in an hour or two!
2008/5/8 Philip Jägenstedt [EMAIL PROTECTED]:
I've used this DynamicRelationType in my project, but there is
something strange going on. Look at what I see in the neo shell:
$ ls
(me) --[INDEX_SERVICE]-- (1)
(me)
Thanks!
On 5/8/08, Mattias Persson [EMAIL PROTECTED] wrote:
I fixed that bug... there will be a new SNAPSHOT of neo in an hour or two!
2008/5/8 Philip Jägenstedt [EMAIL PROTECTED]:
I've used this DynamicRelationType in my project, but there is
something strange going on. Look at what I
2008 19:23
To: Neo user discussions
Subject: Re: [Neo] Does RelationshipType enum need to be unique?
Hi!
Why keep it in a final static map?
why not just:
public final class RelUtil
{
public final static RelationshipType createRelType(final String name)
{
return new
Hi,
the enum approach has the disadvantage that the available relationship types
are static, e.g. they must be known at compile time. In some cases, this may
not be sufficient.
Therefore I have built a DynamicRelationType, which simply looks like this:
public class DynamicRelationshipType
Folks,
that might be a good utility class IMHO, Peter.
/peter
On Mon, May 5, 2008 at 11:20 AM, Peter Haensgen [EMAIL PROTECTED] wrote:
Hi,
the enum approach has the disadvantage that the available relationship
types are static, e.g. they must be known at compile time. In some cases,
this
Hi!
Why keep it in a final static map?
why not just:
public final class RelUtil
{
public final static RelationshipType createRelType(final String name)
{
return new RelationshipType()
{
public String name()
{
return name;
Hi Philip,
So from a Java perspective, your two Enums are definitely different
types and there's no interoperability between them whatsoever. But Neo
ignores that. For Neo, the *name* of a relationship type (as defined
by the Stirng name() method in the RelationshipType interface) is the
unique
Thanks for that explanation, I thought it wouldn't be as simple as it
could be.
Philip
On 5/4/08, Emil Eifrem [EMAIL PROTECTED] wrote:
Hi Philip,
So from a Java perspective, your two Enums are definitely different
types and there's no interoperability between them whatsoever. But Neo
9 matches
Mail list logo