I have a bunch of questions regarding Java 8 and SDN4. I created a model in Neo4j v3.0, played a bit with Cypher queries, and now moved to creating a Spring Boot application. As i started coding classes in Java, I've begun to rethink some of my model as well. Here's some questions in my mind (and I haven't found an example explaining this):
- Do you need to use Interfaces in Java, with SDN?For eg. I'd code a
Product
interface and then have my products implement it, but is that how it's done when working with labels? - This is somewhat tied to my question on inheritance - I'd usually have a
ProductFamily
that myProduct
would inherit from. At the database level its modeled as(:Product)-[PartOf]->(:ProductFamily)
, but in the code these would not be super/sub class. - Any examples of using Generics in a graph context?
- Is there a way to define constraints on what relationships a node can have and their direction in Java?
I understand there is probably not one right answer, but there's precious little on the web, so hope to get enlightened here!