[Neo4j] overriding protected I underlyingObjectToObject(T object) return null

jbeau jbeauregard.ch at gmail.com
Fri Nov 11 12:07:40 CET 2011


Hello Michael,

greetings to the Neustadt :)

I try to realize a multi tenancy environment and started with a first
approach. In a abstract repository I call methods like this:

@Override
 public IClosableIterable findByName(final String name) {
         return
ClosableIterableAdapter.from(getGraphRepository().findAllByPropertyValue("name",
name));
 }

In the ClosableIterableAdapter I posted above I want to avoid putting all
entities into the iterator, which are not valid for the current tenant. The
underlyingObjectToObject() forces to return something. In my case, the non
valid entities are null. I guess it's not a good idea, to filter them later.
I think I have to avoid to put them into the iterator here.

Thx for help
Jack

--
View this message in context: http://neo4j-community-discussions.438527.n3.nabble.com/overriding-protected-I-underlyingObjectToObject-T-object-return-null-tp3499362p3499393.html
Sent from the Neo4j Community Discussions mailing list archive at Nabble.com.


More information about the User mailing list