public final class SerializableField extends Object
Constructor and Description |
---|
SerializableField(Class<?> type,
String name,
boolean unshared) |
Modifier and Type | Method and Description |
---|---|
Field |
getField()
Get the reflection
Field for this serializable field. |
Kind |
getKind()
Get the kind of field.
|
String |
getName()
Get the name of the field.
|
Class<?> |
getType()
Get the field type.
|
boolean |
isUnshared()
Determine whether this field is marked as "unshared".
|
void |
readFrom(Object instance,
ObjectInput input)
Read the field value from the stream.
|
void |
writeTo(Object instance,
ObjectOutput output) |
public Field getField()
Field
for this serializable field. The resultant field will be accessible.public String getName()
public boolean isUnshared()
true
if the field is unsharedpublic Kind getKind()
public Class<?> getType() throws ClassNotFoundException
ClassNotFoundException
public void readFrom(Object instance, ObjectInput input) throws IOException, ClassNotFoundException
instance
- the instanceinput
- the source streamIOException
- if an I/O error occursClassNotFoundException
- if a class could not be loadedpublic void writeTo(Object instance, ObjectOutput output) throws IOException
IOException
Copyright © 2017 JBoss by Red Hat. All rights reserved.