title: Parse JSON and check if it is subtype?
body: <p>What is the simplest and elegant way to parse JSON with Json.Net and check if it is subtype?
  Here is an example.</p>
  
  <p>Shared class library:</p>
  
  <pre><code>public abstract class State {}
  public class PlayerState : State {}
  public class VehicleState : State {}
  </code></pre>
  
  <p>Server-side:</p>
  
  <pre><code> var _state = Utils.GetStateFromString&lt;State&gt;(s);
              if (_state is PlayerState) {
                  PlayerState state = (PlayerState) _state;
                  ...
              }
              else if (_state is VehicleState) {
                  VehicleState state = (VehicleState) _state;
                   ...
              }
  </code></pre>
  
  <p>where s is serialized string from client.  </p>
  
  <p>I get it's works only using  <code>TypeNameHandling = TypeNameHandling.Objects</code>
  and creating custom SerializationBinder, but it is very hart to add all types to binder, because of there are different assemblies on client and server.
  I know about JsonSubType lib, but my platform doesn't allow adding links in project</p>