I - vertexId type parameterT - vertexData type parameterpublic abstract class AbstractVertexIdData<I extends org.apache.hadoop.io.WritableComparable,T> extends Object implements VertexIdData<I,T>
| Modifier and Type | Field and Description |
|---|---|
protected ExtendedDataOutput |
extendedDataOutput
Extended data output
|
| Constructor and Description |
|---|
AbstractVertexIdData() |
| Modifier and Type | Method and Description |
|---|---|
void |
add(byte[] serializedId,
int idPos,
T data)
Add a serialized vertex id and data.
|
void |
add(I vertexId,
T data)
Add a vertex id and data pair to the collection.
|
void |
clear()
Clear the list.
|
ImmutableClassesGiraphConfiguration<I,?,?> |
getConf()
Return the configuration used by this object.
|
int |
getSerializedSize()
Get the size of this object in serialized form.
|
int |
getSize()
Get the number of bytes used.
|
ByteStructVertexIdDataIterator<I,T> |
getVertexIdDataIterator()
Get an iterator over the pairs.
|
void |
initialize()
Initialize the inner state.
|
void |
initialize(int expectedSize)
Initialize the inner state, with a known size.
|
boolean |
isEmpty()
Check if the list is empty.
|
void |
readFields(DataInput dataInput) |
void |
setConf(ImmutableClassesGiraphConfiguration configuration)
Set the configuration to be used by this object.
|
void |
write(DataOutput output) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcreateData, readData, writeDataprotected ExtendedDataOutput extendedDataOutput
public void initialize()
VertexIdDataadd() is
called.initialize in interface VertexIdData<I extends org.apache.hadoop.io.WritableComparable,T>public void initialize(int expectedSize)
VertexIdDataadd() is called.initialize in interface VertexIdData<I extends org.apache.hadoop.io.WritableComparable,T>expectedSize - Number of bytes to be expectedpublic void add(I vertexId, T data)
VertexIdDataadd in interface VertexIdData<I extends org.apache.hadoop.io.WritableComparable,T>vertexId - Vertex iddata - Datapublic void add(byte[] serializedId,
int idPos,
T data)
VertexIdDataadd in interface VertexIdData<I extends org.apache.hadoop.io.WritableComparable,T>serializedId - The bye array which holds the serialized id.idPos - The end position of the serialized id in the byte array.data - Datapublic int getSize()
VertexIdDatagetSize in interface VertexIdData<I extends org.apache.hadoop.io.WritableComparable,T>public int getSerializedSize()
VertexIdDatagetSerializedSize in interface VertexIdData<I extends org.apache.hadoop.io.WritableComparable,T>public boolean isEmpty()
VertexIdDataisEmpty in interface VertexIdData<I extends org.apache.hadoop.io.WritableComparable,T>public void clear()
VertexIdDataclear in interface VertexIdData<I extends org.apache.hadoop.io.WritableComparable,T>public void setConf(ImmutableClassesGiraphConfiguration configuration)
GiraphConfigurationSettablesetConf in interface GiraphConfigurationSettableconfiguration - Set configurationpublic ImmutableClassesGiraphConfiguration<I,?,?> getConf()
ImmutableClassesGiraphConfigurablegetConf in interface ImmutableClassesGiraphConfigurablepublic ByteStructVertexIdDataIterator<I,T> getVertexIdDataIterator()
VertexIdDatagetVertexIdDataIterator in interface VertexIdData<I extends org.apache.hadoop.io.WritableComparable,T>public void write(DataOutput output) throws IOException
write in interface org.apache.hadoop.io.WritableIOExceptionpublic void readFields(DataInput dataInput) throws IOException
readFields in interface org.apache.hadoop.io.WritableIOExceptionCopyright © 2011-2020 The Apache Software Foundation. All Rights Reserved.