Class DegreeRangeImmutableSubgraph

java.lang.Object
it.unimi.dsi.webgraph.ImmutableGraph
it.unimi.dsi.webgraph.ImmutableSubgraph
it.unimi.dsi.webgraph.DegreeRangeImmutableSubgraph
All Implemented Interfaces:
FlyweightPrototype<ImmutableGraph>

public class DegreeRangeImmutableSubgraph
extends ImmutableSubgraph
A subclass of ImmutableSubgraph exposing the subgraph formed by nodes whose outdegree is in a given range.

Note that the string-based constructors can be used with an ObjectParser to specify a graph on the command line.

  • Constructor Details

    • DegreeRangeImmutableSubgraph

      public DegreeRangeImmutableSubgraph​(ImmutableGraph graph, int minDegree, int maxDegree)
      Create a subgraph formed by the nodes with outdegree in a specified range.
      Parameters:
      graph - the supergraph.
      minDegree - the minimum outdegree (inclusive).
      maxDegree - the maximum outdegree (exclusive).
    • DegreeRangeImmutableSubgraph

      public DegreeRangeImmutableSubgraph​(java.lang.String graph, java.lang.String minDegree, java.lang.String maxDegree) throws java.io.IOException
      Create a subgraph formed by the nodes with outdegree in a specified range.

      This is a string-based constructor that can be used with an ObjectParser.

      Parameters:
      graph - the supergraph.
      minDegree - the minimum outdegree (inclusive).
      maxDegree - the meximum outdegree (exclusive).
      Throws:
      java.io.IOException
    • DegreeRangeImmutableSubgraph

      public DegreeRangeImmutableSubgraph​(java.lang.String graph, java.lang.String minDegree, java.lang.String maxDegree, java.lang.String mapped) throws java.io.IOException
      Create a subgraph formed by the nodes with outdegree in a specified range.

      This is a string-based constructor that can be used with an ObjectParser.

      Parameters:
      graph - the supergraph.
      minDegree - the minimum outdegree (inclusive).
      maxDegree - the maximum outdegree (exclusive).
      mapped - if true, the supergraph will be loaded with ImmutableGraph.loadMapped(CharSequence, it.unimi.dsi.logging.ProgressLogger) instead of ImmutableGraph.load(CharSequence, it.unimi.dsi.logging.ProgressLogger).
      Throws:
      java.io.IOException
  • Method Details