Class FederatedGraphStorage


  • public class FederatedGraphStorage
    extends Object
    • Constructor Detail

      • FederatedGraphStorage

        public FederatedGraphStorage​(String suffixFederatedStoreCacheName)
    • Method Detail

      • getAllIds

        public List<String> getAllIds​(User user)
        Returns all the graphIds that are visible for the given user.
        Parameters:
        user - to match visibility against.
        Returns:
        visible graphIds.
      • getAll

        public Collection<GraphSerialisable> getAll​(User user)
        Returns all graph object that are visible for the given user.
        Parameters:
        user - to match visibility against.
        Returns:
        visible graphs
      • remove

        public boolean remove​(String graphId,
                              User user,
                              boolean removeCache)
        Removes a graph from storage and returns the success. The given user must have visibility of the graph to be able to remove it.
        Parameters:
        graphId - the graphId to remove.
        user - to match visibility against.
        removeCache - to remove associated caches with this graph.
        Returns:
        if a graph was removed.
        See Also:
        isValidToView(User, FederatedAccess)
      • get

        public Collection<GraphSerialisable> get​(User user,
                                                 List<String> graphIds)
        returns all graphs objects matching the given graphIds, that is visible to the user.
        Parameters:
        user - to match visibility against.
        graphIds - the graphIds to get graphs for.
        Returns:
        visible graphs from the given graphIds.
      • get

        public List<GraphSerialisable> get​(User user,
                                           List<String> graphIds,
                                           String adminAuth)
        returns all graphs objects matching the given graphIds, that is visible to the user.
        Parameters:
        user - to match visibility against.
        graphIds - the graphIds to get graphs for. List is used because it preserves order.
        adminAuth - adminAuths role
        Returns:
        visible graphs from the given graphIds.
      • setGraphLibrary

        public void setGraphLibrary​(GraphLibrary graphLibrary)