public override IndexHits <Relationship> Query(object queryOrQueryObjectOrNull, Node startNodeOrNull, Node endNodeOrNull) { KernelTransaction ktx = TxBridge.get(); try { using (Statement ignore = ktx.AcquireStatement()) { RelationshipExplicitIndexCursor cursor = ktx.Cursors().allocateRelationshipExplicitIndexCursor(); long source = startNodeOrNull == null ? NO_SUCH_NODE : startNodeOrNull.Id; long target = endNodeOrNull == null ? NO_SUCH_NODE : endNodeOrNull.Id; ktx.IndexRead().relationshipExplicitIndexQuery(cursor, NameConflict, queryOrQueryObjectOrNull, source, target); return(new CursorWrappingRelationshipIndexHits(cursor, GraphDatabase, ktx, NameConflict)); } } catch (ExplicitIndexNotFoundKernelException) { throw new NotFoundException(Type + " index '" + NameConflict + "' doesn't exist"); } }