package data.domain.nodes; import org.neo4j.graphdb.Direction; import org.springframework.data.neo4j.annotation.Fetch; import org.springframework.data.neo4j.annotation.GraphId; import org.springframework.data.neo4j.annotation.NodeEntity; import org.springframework.data.neo4j.annotation.RelatedTo; import java.util.Set; @NodeEntity public class Content { @GraphId private Long id; private String title; private String url; @Fetch @RelatedTo(type = "ON", direction = Direction.INCOMING) Set<Event> events; public String getTitle() { return title; } public void setTitle(String title) { this.title = title; } public String getUrl() { return url; } public void setUrl(String url) { this.url = url; } }