Interface RelationManager

    • Method Detail

      • getGraph

        Graph getGraph​(String name,
                       CoreSession session)
        Gets a registered graph by name.

        A CoreSession should be passed to provide a context in which to store relations when using a "core" graph.

        Parameters:
        name - string name of the graph used at registration
        session - the core session
        Returns:
        the graph
        Throws:
        RuntimeException - if the graph is not found
        Since:
        5.5
      • getGraphByName

        Graph getGraphByName​(String name)
        Gets a registered graph by name.
        Parameters:
        name - string name of the graph used at registration
        Returns:
        the graph
        Throws:
        RuntimeException - if the graph is not found
      • getTransientGraph

        Graph getTransientGraph​(String type)
        Gets a transient graph.
        Parameters:
        type - The graph type.
        Returns:
        the graph.
      • getResource

        Resource getResource​(String namespace,
                             Serializable object,
                             Map<String,​Object> context)
        Gets a resource given a namespace and a serializable object.

        There can be several resources with different namespaces associated to an incoming object. A document can for instance be used to refer to itself as a precise version as well as to the set of all versions.

        Context can hold any object useful for the adapters, like a CoreSession.

        Since:
        5.2-M1