Interface IdMapping

    • Field Detail

      • START_NODE_ID

        static final long START_NODE_ID
        Defines the lower bound of mapped ids TODO: function?
        See Also:
        Constant Field Values
      • NOT_FOUND

        static final long NOT_FOUND
        Defines the value for unmapped ids
        See Also:
        Constant Field Values
    • Method Detail

      • toMappedNodeId

        long toMappedNodeId​(long nodeId)
        Map original nodeId to inner nodeId
        Parameters:
        nodeId - must be smaller or equal to the id returned by highestNeoId()
      • safeToMappedNodeId

        default long safeToMappedNodeId​(long nodeId)
        Map original nodeId to inner nodeId Returns org.neo4j.gds.api.IdMapping#NOT_FOUND if the nodeId is not mapped.
      • toOriginalNodeId

        long toOriginalNodeId​(long nodeId)
        Map inner nodeId back to original nodeId
      • toRootNodeId

        long toRootNodeId​(long nodeId)
        Maps an internal id to its root internal node id. This is necessary for nested (filtered) id mappings. If this mapping is a nested mapping, this method returns the root node id of the parent mapping. For the root mapping this method returns the given node id.
      • contains

        boolean contains​(long nodeId)
        Returns true iff the nodeId is mapped, otherwise false.
      • nodeCount

        long nodeCount()
        Number of mapped nodeIds.
      • rootNodeCount

        long rootNodeCount()
        Number of mapped node ids in the root mapping. This is necessary for nested (filtered) id mappings.
      • highestNeoId

        long highestNeoId()
      • cloneIdMapping

        default IdMapping cloneIdMapping()