Database Reference
In-Depth Information
Figure 9.6. Overview of SDN repository classes involved in accessing User node entity
The following one-line snippet shows the definition of the UserRepository interface,
specifically for the User domain (node entity) class:
public interface UserRepository extends GraphRepository<User> { }
In this case, the UserRepository interface is extending the GraphRepository in-
terface, which defines the broadest set of default operations available for a domain class.
TheuseofJavagenericstiesthisrepository(atcompiletime,anyway)tothe User domain
entity.
The GraphRepository interface essentially consolidates all the other interfaces and
thus defines operations covering CRUD, indexing, and traversals for a user. The following
list shows some of the default operations that the GraphRepository interface covers:
public <U extends User> U save(U entity);
 
Search WWH ::




Custom Search