public class Person extends java.lang.Object implements DataSerializable
DataSerializable.Replaceable| Modifier and Type | Field and Description |
|---|---|
static boolean |
THROW_ON_INDEX |
| Constructor and Description |
|---|
Person() |
Person(java.lang.String name,
int age) |
| Modifier and Type | Method and Description |
|---|---|
void |
fromData(java.io.DataInput in)
Reads the state of this object as primitive data from the given
DataInput. |
int |
getAge() |
java.lang.String |
getName() |
boolean |
index() |
void |
setAge(int age) |
void |
setName(java.lang.String name) |
void |
toData(java.io.DataOutput out)
Writes the state of this object as primitive data to the given
DataOutput. |
java.lang.String |
toString() |
public void setName(java.lang.String name)
public java.lang.String getName()
public void setAge(int age)
public int getAge()
public java.lang.String toString()
toString in class java.lang.Objectpublic boolean index()
public void toData(java.io.DataOutput out)
throws java.io.IOException
DataSerializableDataOutput.
Since 5.7 it is possible for any method call to the specified DataOutput to throw
GemFireRethrowable. It should not be caught by user code. If it is it
must be rethrown.
toData in interface DataSerializablejava.io.IOException - A problem occurs while writing to outpublic void fromData(java.io.DataInput in)
throws java.io.IOException,
java.lang.ClassNotFoundException
DataSerializableDataInput.fromData in interface DataSerializablejava.io.IOException - A problem occurs while reading from injava.lang.ClassNotFoundException - A class could not be loaded while reading from in