Skip to content

IAirContentProcessor

Viridovics edited this page Sep 2, 2018 · 4 revisions

Description

IAirContentProcessor describes behavior of serialization (for request body)/deserialization (for response content) and content type.

    public interface IAirContentProcessor
    {
        string ContentType { get; } // You can use AirHttp.Protocols.ContentTypes constants for implementation of _ContentType_

        T DeserializeObject<T>(string serializedObject);

        string SerializeObject<T>(T pocoObject);
    }

Implementation examples

Embedded implementations

SimpleJsonContentProcessor

Implementation

Features

  • Support DataContracts
  • Case sensitive for fields naming

WeakJsonContentProcessor

Implementation

Features

  • Case insensitive for fields naming
  • Warning: There may be naming collisions