congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
UndirectedGraphConnections.ofImmutable
Code IndexAdd Tabnine to your IDE (free)

How to use
ofImmutable
method
in
com.google.common.graph.UndirectedGraphConnections

Best Java code snippets using com.google.common.graph.UndirectedGraphConnections.ofImmutable (Showing top 10 results out of 315)

origin: google/guava

private static <N> GraphConnections<N, Presence> connectionsOf(Graph<N> graph, N node) {
 Function<Object, Presence> edgeValueFn = Functions.constant(Presence.EDGE_EXISTS);
 return graph.isDirected()
   ? DirectedGraphConnections.ofImmutable(
     graph.predecessors(node), Maps.asMap(graph.successors(node), edgeValueFn))
   : UndirectedGraphConnections.ofImmutable(
     Maps.asMap(graph.adjacentNodes(node), edgeValueFn));
}
origin: google/guava

 private static <N, V> GraphConnections<N, V> connectionsOf(
   final ValueGraph<N, V> graph, final N node) {
  Function<N, V> successorNodeToValueFn =
    new Function<N, V>() {
     @Override
     public V apply(N successorNode) {
      return graph.edgeValueOrDefault(node, successorNode, null);
     }
    };
  return graph.isDirected()
    ? DirectedGraphConnections.ofImmutable(
      graph.predecessors(node), Maps.asMap(graph.successors(node), successorNodeToValueFn))
    : UndirectedGraphConnections.ofImmutable(
      Maps.asMap(graph.adjacentNodes(node), successorNodeToValueFn));
 }
}
origin: google/j2objc

 private static <N, V> GraphConnections<N, V> connectionsOf(
   final ValueGraph<N, V> graph, final N node) {
  Function<N, V> successorNodeToValueFn =
    new Function<N, V>() {
     @Override
     public V apply(N successorNode) {
      return graph.edgeValueOrDefault(node, successorNode, null);
     }
    };
  return graph.isDirected()
    ? DirectedGraphConnections.ofImmutable(
      graph.predecessors(node), Maps.asMap(graph.successors(node), successorNodeToValueFn))
    : UndirectedGraphConnections.ofImmutable(
      Maps.asMap(graph.adjacentNodes(node), successorNodeToValueFn));
 }
}
origin: google/j2objc

private static <N> GraphConnections<N, Presence> connectionsOf(Graph<N> graph, N node) {
 Function<Object, Presence> edgeValueFn = Functions.constant(Presence.EDGE_EXISTS);
 return graph.isDirected()
   ? DirectedGraphConnections.ofImmutable(
     graph.predecessors(node), Maps.asMap(graph.successors(node), edgeValueFn))
   : UndirectedGraphConnections.ofImmutable(
     Maps.asMap(graph.adjacentNodes(node), edgeValueFn));
}
origin: wildfly/wildfly

private static <N> GraphConnections<N, Presence> connectionsOf(Graph<N> graph, N node) {
 Function<Object, Presence> edgeValueFn = Functions.constant(Presence.EDGE_EXISTS);
 return graph.isDirected()
   ? DirectedGraphConnections.ofImmutable(
     graph.predecessors(node), Maps.asMap(graph.successors(node), edgeValueFn))
   : UndirectedGraphConnections.ofImmutable(
     Maps.asMap(graph.adjacentNodes(node), edgeValueFn));
}
origin: wildfly/wildfly

 private static <N, V> GraphConnections<N, V> connectionsOf(
   final ValueGraph<N, V> graph, final N node) {
  Function<N, V> successorNodeToValueFn =
    new Function<N, V>() {
     @Override
     public V apply(N successorNode) {
      return graph.edgeValueOrDefault(node, successorNode, null);
     }
    };
  return graph.isDirected()
    ? DirectedGraphConnections.ofImmutable(
      graph.predecessors(node), Maps.asMap(graph.successors(node), successorNodeToValueFn))
    : UndirectedGraphConnections.ofImmutable(
      Maps.asMap(graph.adjacentNodes(node), successorNodeToValueFn));
 }
}
origin: org.kill-bill.billing/killbill-platform-osgi-bundles-logger

private static <N> GraphConnections<N, Presence> connectionsOf(Graph<N> graph, N node) {
 Function<Object, Presence> edgeValueFn = Functions.constant(Presence.EDGE_EXISTS);
 return graph.isDirected()
   ? DirectedGraphConnections.ofImmutable(
     graph.predecessors(node), Maps.asMap(graph.successors(node), edgeValueFn))
   : UndirectedGraphConnections.ofImmutable(
     Maps.asMap(graph.adjacentNodes(node), edgeValueFn));
}
origin: org.jboss.eap/wildfly-client-all

private static <N> GraphConnections<N, Presence> connectionsOf(Graph<N> graph, N node) {
 Function<Object, Presence> edgeValueFn = Functions.constant(Presence.EDGE_EXISTS);
 return graph.isDirected()
   ? DirectedGraphConnections.ofImmutable(
     graph.predecessors(node), Maps.asMap(graph.successors(node), edgeValueFn))
   : UndirectedGraphConnections.ofImmutable(
     Maps.asMap(graph.adjacentNodes(node), edgeValueFn));
}
origin: org.kill-bill.billing/killbill-platform-osgi-bundles-logger

 private static <N, V> GraphConnections<N, V> connectionsOf(
   final ValueGraph<N, V> graph, final N node) {
  Function<N, V> successorNodeToValueFn =
    new Function<N, V>() {
     @Override
     public V apply(N successorNode) {
      return graph.edgeValueOrDefault(node, successorNode, null);
     }
    };
  return graph.isDirected()
    ? DirectedGraphConnections.ofImmutable(
      graph.predecessors(node), Maps.asMap(graph.successors(node), successorNodeToValueFn))
    : UndirectedGraphConnections.ofImmutable(
      Maps.asMap(graph.adjacentNodes(node), successorNodeToValueFn));
 }
}
origin: org.jboss.eap/wildfly-client-all

 private static <N, V> GraphConnections<N, V> connectionsOf(
   final ValueGraph<N, V> graph, final N node) {
  Function<N, V> successorNodeToValueFn =
    new Function<N, V>() {
     @Override
     public V apply(N successorNode) {
      return graph.edgeValueOrDefault(node, successorNode, null);
     }
    };
  return graph.isDirected()
    ? DirectedGraphConnections.ofImmutable(
      graph.predecessors(node), Maps.asMap(graph.successors(node), successorNodeToValueFn))
    : UndirectedGraphConnections.ofImmutable(
      Maps.asMap(graph.adjacentNodes(node), successorNodeToValueFn));
 }
}
com.google.common.graphUndirectedGraphConnectionsofImmutable

Popular methods of UndirectedGraphConnections

  • <init>
  • addSuccessor
  • adjacentNodes
  • of
  • removeSuccessor

Popular in Java

  • Reactive rest calls using spring rest template
  • getApplicationContext (Context)
  • setRequestProperty (URLConnection)
  • onRequestPermissionsResult (Fragment)
  • BigInteger (java.math)
    An immutable arbitrary-precision signed integer.FAST CRYPTOGRAPHY This implementation is efficient f
  • SocketTimeoutException (java.net)
    This exception is thrown when a timeout expired on a socket read or accept operation.
  • Enumeration (java.util)
    A legacy iteration interface.New code should use Iterator instead. Iterator replaces the enumeration
  • GregorianCalendar (java.util)
    GregorianCalendar is a concrete subclass of Calendarand provides the standard calendar used by most
  • ZipFile (java.util.zip)
    This class provides random read access to a zip file. You pay more to read the zip file's central di
  • Cipher (javax.crypto)
    This class provides access to implementations of cryptographic ciphers for encryption and decryption
  • Top 12 Jupyter Notebook extensions
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now