public static < N > ImmutableGraph < N > singletonDirectedGraph ( N node ) { final MutableGraph < N > graph = GraphBuilder . directed ( ) . build ( ) ; graph . addNode ( node ) ; return ImmutableGraph . copyOf ( graph ) ; }
Returns an immutable directed graph containing only the specified node .