クラス SerializationUtils

java.lang.ObjectSE
org.springframework.amqp.utils.SerializationUtils

public final class SerializationUtils extends ObjectSE
直列化を支援する静的ユーティリティ。
作成者:
Dave Syer, Gary Russell, Artem Bilan
  • メソッドの詳細

    • serialize

      public static byte[] serialize(ObjectSE object)
      提供されたオブジェクトを直列化します。
      パラメーター:
      object - 直列化するオブジェクト
      戻り値:
      移植可能な方法でオブジェクトを表すバイトの配列
    • deserialize

      public static ObjectSE deserialize(byte[] bytes)
      バイトを逆直列化します。
      パラメーター:
      bytes - 作成された直列化されたオブジェクト
      戻り値:
      バイトを逆直列化した結果
    • deserialize

      public static ObjectSE deserialize(ObjectInputStreamSE stream)
      ストリームを逆直列化します。
      パラメーター:
      stream - 直列化されたオブジェクトから作成されたオブジェクトストリーム
      戻り値:
      バイトを逆直列化した結果
    • deserialize

      public static ObjectSE deserialize(InputStreamSE inputStream, SetSE<StringSE> allowedListPatterns, ClassLoaderSE classLoader) throws IOExceptionSE
      ストリームを逆直列化します。
      パラメーター:
      inputStream - ストリーム。
      allowedListPatterns - 許可されたクラス。
      classLoader - クラスローダー。
      戻り値:
      結果。
      例外:
      IOExceptionSE - IO 例外。
      導入:
      2.1
    • checkAllowedList

      public static void checkAllowedList(ClassSE<?> clazz, SetSE<StringSE> patterns)
      クラスが許可リストにあることを確認します。
      パラメーター:
      clazz - クラス。
      patterns - パターン。
      導入:
      2.1