private void ThrowInvalidReplicationHistoryType(JsonParserState state, IJsonParser reader)
 {
     throw new InvalidDataException($"Expected property @metadata.Raven-Replication-History to have array type, but was: {state.CurrentTokenType}. Id: '{Id ?? "N/A"}'. Around: {reader.GenerateErrorState()}");
 }
 private void ThrowExpectedProperty()
 {
     throw new InvalidDataException("Expected property, but got " + _state.CurrentTokenType + _reader.GenerateErrorState());
 }
 private void ThrowInvalidEtagType(JsonParserState state, IJsonParser reader)
 {
     throw new InvalidDataException($"Expected property @metadata.@etag to have string or long type, but was: {state.CurrentTokenType}. Id: '{Id ?? "N/A"}'. Around: {reader.GenerateErrorState()}");
 }
        private void ThrowInvalidLastModifiedProperty(State state, LazyStringValue str, IJsonParser reader)
        {
            var field = state == State.ReadingLastModified ? Constants.Documents.Metadata.LastModified : LegacyLastModified;

            throw new InvalidDataException($"Cannot parse the value of property @metadata.{field}: {str}. Id: '{Id ?? "N/A"}'. Around: {reader.GenerateErrorState()}");
        }
 private void ThrowInvalidFlagsProperty(LazyStringValue str, IJsonParser reader)
 {
     throw new InvalidDataException($"Cannot parse the value of property @metadata.@flags: {str}. Id: '{Id ?? "N/A"}'. Around: {reader.GenerateErrorState()}");
 }
 private void ThrowExpectedFieldTypeOfString(string field, JsonParserState state, IJsonParser reader)
 {
     throw new InvalidDataException($"Expected property @metadata.{field} to have string type, but was: {state.CurrentTokenType}. Id: '{Id ?? "N/A"}'. Around: {reader.GenerateErrorState()}");
 }
 private void ThrowInvalidMetadataProperty(JsonParserState state, IJsonParser reader)
 {
     throw new InvalidDataException($"Expected property @metadata to be a simpel type, but was {state.CurrentTokenType}. Id: '{Id ?? "N/A"}'. Around {reader.GenerateErrorState()}");
 }