public class IntNullArrayEdges extends Object implements ReuseObjectsOutEdges<org.apache.hadoop.io.IntWritable,org.apache.hadoop.io.NullWritable>, Trimmable
OutEdges with int ids and null edge
 values, backed by dynamic primitive array.
 Parallel edges are allowed.
 Note: this implementation is optimized for space usage,
 but edge removals are expensive.| Constructor and Description | 
|---|
| IntNullArrayEdges() | 
| Modifier and Type | Method and Description | 
|---|---|
| void | add(Edge<org.apache.hadoop.io.IntWritable,org.apache.hadoop.io.NullWritable> edge)Add an edge. | 
| void | initialize()Initialize the data structure with the default initial capacity. | 
| void | initialize(int capacity)Initialize the data structure with the specified initial capacity. | 
| void | initialize(Iterable<Edge<org.apache.hadoop.io.IntWritable,org.apache.hadoop.io.NullWritable>> edges)Initialize the data structure and set the edges from an iterable. | 
| Iterator<Edge<org.apache.hadoop.io.IntWritable,org.apache.hadoop.io.NullWritable>> | iterator() | 
| void | readFields(DataInput in) | 
| void | remove(org.apache.hadoop.io.IntWritable targetVertexId)Remove all edges to the given target vertex. | 
| int | size()Return the number of edges. | 
| void | trim()Compacts all recent updates to this object. | 
| void | write(DataOutput out) | 
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEach, spliteratorpublic void initialize(Iterable<Edge<org.apache.hadoop.io.IntWritable,org.apache.hadoop.io.NullWritable>> edges)
OutEdgesinitialize in interface OutEdges<org.apache.hadoop.io.IntWritable,org.apache.hadoop.io.NullWritable>edges - Iterable of edgespublic void initialize(int capacity)
OutEdgesinitialize in interface OutEdges<org.apache.hadoop.io.IntWritable,org.apache.hadoop.io.NullWritable>capacity - Initial capacitypublic void initialize()
OutEdgesinitialize in interface OutEdges<org.apache.hadoop.io.IntWritable,org.apache.hadoop.io.NullWritable>public int size()
OutEdgespublic void add(Edge<org.apache.hadoop.io.IntWritable,org.apache.hadoop.io.NullWritable> edge)
OutEdgespublic void remove(org.apache.hadoop.io.IntWritable targetVertexId)
OutEdgespublic Iterator<Edge<org.apache.hadoop.io.IntWritable,org.apache.hadoop.io.NullWritable>> iterator()
public void write(DataOutput out) throws IOException
write in interface org.apache.hadoop.io.WritableIOExceptionpublic void readFields(DataInput in) throws IOException
readFields in interface org.apache.hadoop.io.WritableIOExceptionCopyright © 2011-2020 The Apache Software Foundation. All Rights Reserved.