|
||||||||||
前のクラス 次のクラス | フレームあり フレームなし | |||||||||
概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド |
java.lang.Objectcom.jme3.network.serializing.Serializer
public abstract class Serializer
The main serializer class, which will serialize objects such that they can be sent across the network. Serializing classes should extend this to provide their own serialization.
コンストラクタの概要 | |
---|---|
Serializer()
|
メソッドの概要 | ||
---|---|---|
static Serializer |
getExactSerializer(java.lang.Class cls)
|
|
static SerializerRegistration |
getExactSerializerRegistration(java.lang.Class cls)
|
|
static Serializer |
getSerializer(java.lang.Class cls)
|
|
static Serializer |
getSerializer(java.lang.Class cls,
boolean failOnMiss)
|
|
static SerializerRegistration |
getSerializerRegistration(java.lang.Class cls)
|
|
static SerializerRegistration |
getSerializerRegistration(java.lang.Class cls,
boolean failOnMiss)
|
|
void |
initialize(java.lang.Class clazz)
Registration for when a serializer may need to cache something. |
|
static SerializerRegistration |
readClass(java.nio.ByteBuffer buffer)
Read the class from given buffer and return its SerializerRegistration. |
|
static java.lang.Object |
readClassAndObject(java.nio.ByteBuffer buffer)
Read the class and the object. |
|
abstract
|
readObject(java.nio.ByteBuffer data,
java.lang.Class<T> c)
Read an object from the buffer, effectively deserializing it. |
|
static SerializerRegistration |
registerClass(java.lang.Class cls)
|
|
static SerializerRegistration |
registerClass(java.lang.Class cls,
boolean failOnMiss)
Registers the specified class. |
|
static SerializerRegistration |
registerClass(java.lang.Class cls,
Serializer serializer)
|
|
static SerializerRegistration[] |
registerPackage(java.lang.String pkgName)
推奨されていません。 This cannot be implemented in a reasonable way that works in all deployment methods. |
|
static void |
setStrictRegistration(boolean b)
When set to true, classes that do not have intrinsic IDs in their |
|
static SerializerRegistration |
writeClass(java.nio.ByteBuffer buffer,
java.lang.Class type)
Write a class and return its SerializerRegistration. |
|
static void |
writeClassAndObject(java.nio.ByteBuffer buffer,
java.lang.Object object)
Write the class and object. |
|
abstract void |
writeObject(java.nio.ByteBuffer buffer,
java.lang.Object object)
Write an object to the buffer, effectively serializing it. |
クラス java.lang.Object から継承されたメソッド |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
コンストラクタの詳細 |
---|
public Serializer()
メソッドの詳細 |
---|
public static void setStrictRegistration(boolean b)
public static SerializerRegistration registerClass(java.lang.Class cls)
public static SerializerRegistration registerClass(java.lang.Class cls, boolean failOnMiss)
@Deprecated public static SerializerRegistration[] registerPackage(java.lang.String pkgName)
public static SerializerRegistration registerClass(java.lang.Class cls, Serializer serializer)
public static Serializer getExactSerializer(java.lang.Class cls)
public static Serializer getSerializer(java.lang.Class cls)
public static Serializer getSerializer(java.lang.Class cls, boolean failOnMiss)
public static SerializerRegistration getExactSerializerRegistration(java.lang.Class cls)
public static SerializerRegistration getSerializerRegistration(java.lang.Class cls)
public static SerializerRegistration getSerializerRegistration(java.lang.Class cls, boolean failOnMiss)
public static SerializerRegistration readClass(java.nio.ByteBuffer buffer)
buffer
- The buffer to read from.
public static java.lang.Object readClassAndObject(java.nio.ByteBuffer buffer) throws java.io.IOException
buffer
- Buffer to read from.
java.io.IOException
- If serialization failed.public static SerializerRegistration writeClass(java.nio.ByteBuffer buffer, java.lang.Class type)
buffer
- The buffer to write the given class to.type
- The class to write.
public static void writeClassAndObject(java.nio.ByteBuffer buffer, java.lang.Object object) throws java.io.IOException
buffer
- The buffer to write to.object
- The object to write.
java.io.IOException
- If serializing fails.public abstract <T> T readObject(java.nio.ByteBuffer data, java.lang.Class<T> c) throws java.io.IOException
data
- The buffer to read from.c
- The class of the object.
java.io.IOException
- If deserializing fails.public abstract void writeObject(java.nio.ByteBuffer buffer, java.lang.Object object) throws java.io.IOException
buffer
- The buffer to write to.object
- The object to serialize.
java.io.IOException
- If serializing fails.public void initialize(java.lang.Class clazz)
clazz
- The class that has been registered to the serializer.
|
||||||||||
前のクラス 次のクラス | フレームあり フレームなし | |||||||||
概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド |