• CacheManager
  • Documentation
  • Api Docs
  • MichaCo.net
    Show / Hide Table of Contents

    Class BinaryCacheSerializer

    Basic binary serialization implementation of the ICacheSerializer. This implementation will be used in case no other serializer is configured for the cache manager and serialization is needed (only distributed caches will have to serialize the cache value). Binary serialization will not be available in some environments.

    Inheritance
    Object
    BinaryCacheSerializer
    Inherited Members
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace:CacheManager.Core.Internal
    Assembly:CacheManager.Core.dll
    Syntax
    public class BinaryCacheSerializer : ICacheSerializer

    Constructors

    | Improve this Doc View Source

    BinaryCacheSerializer()

    Initializes a new instance of the BinaryCacheSerializer class.

    Declaration
    public BinaryCacheSerializer()
    | Improve this Doc View Source

    BinaryCacheSerializer(BinaryFormatter, BinaryFormatter)

    Initializes a new instance of the BinaryCacheSerializer class.

    Declaration
    public BinaryCacheSerializer(BinaryFormatter serializationFormatter, BinaryFormatter deserializationFormatter)
    Parameters
    Type Name Description
    BinaryFormatter serializationFormatter

    The formatter to use to do the serialization.

    BinaryFormatter deserializationFormatter

    The formatter to use to do the deserialization.

    Properties

    | Improve this Doc View Source

    DeserializationFormatter

    Gets the formatter which should be used during deserialization. If nothing is specified the default BinaryFormatter will be used.

    Declaration
    public BinaryFormatter DeserializationFormatter { get; }
    Property Value
    Type Description
    BinaryFormatter

    The deserialization formatter.

    | Improve this Doc View Source

    SerializationFormatter

    Gets the formatter which should be used during serialization. If nothing is specified the default BinaryFormatter will be used.

    Declaration
    public BinaryFormatter SerializationFormatter { get; }
    Property Value
    Type Description
    BinaryFormatter

    The serialization formatter.

    Methods

    | Improve this Doc View Source

    Deserialize(Byte[], Type)

    Declaration
    public object Deserialize(byte[] data, Type target)
    Parameters
    Type Name Description
    System.Byte[] data
    Type target
    Returns
    Type Description
    Object
    Implements
    ICacheSerializer.Deserialize(Byte[], Type)
    | Improve this Doc View Source

    DeserializeCacheItem<T>(Byte[], Type)

    Declaration
    public CacheItem<T> DeserializeCacheItem<T>(byte[] value, Type valueType)
    Parameters
    Type Name Description
    System.Byte[] value
    Type valueType
    Returns
    Type Description
    CacheItem<T>
    Type Parameters
    Name Description
    T
    Implements
    ICacheSerializer.DeserializeCacheItem<T>(Byte[], Type)
    | Improve this Doc View Source

    Serialize<T>(T)

    Declaration
    public byte[] Serialize<T>(T value)
    Parameters
    Type Name Description
    T value
    Returns
    Type Description
    System.Byte[]
    Type Parameters
    Name Description
    T
    Implements
    ICacheSerializer.Serialize<T>(T)
    | Improve this Doc View Source

    SerializeCacheItem<T>(CacheItem<T>)

    Declaration
    public byte[] SerializeCacheItem<T>(CacheItem<T> value)
    Parameters
    Type Name Description
    CacheItem<T> value
    Returns
    Type Description
    System.Byte[]
    Type Parameters
    Name Description
    T
    Implements
    ICacheSerializer.SerializeCacheItem<T>(CacheItem<T>)
    • Improve this Doc
    • View Source
    © 2025 by Michael Conrad. All rights reserved. - MichaCo.net