@Override
  public BatchKVResponse<K, EntityResponse<V>> wrapResponse(DataMap dataMap, Map<String, String> headers, ProtocolVersion version)
    throws InstantiationException, IllegalAccessException, InvocationTargetException, NoSuchMethodException, IOException
  {
    if (dataMap == null)
    {
      return null;
    }

    return new BatchEntityResponse<>(dataMap, _keyType, _entityType, _keyParts, _complexKeyType, version);
  }
@Test(dataProvider = TestConstants.RESTLI_PROTOCOL_1_2_PREFIX + "batchEntityResponseDataProvider")
  public void testDecodingWithEmptyDataMap(List<String> keys, ProtocolVersion protocolVersion)
    throws InstantiationException, IllegalAccessException, InvocationTargetException, NoSuchMethodException, IOException
  {
    final BatchEntityResponseDecoder<String, TestRecord> decoder =
        new BatchEntityResponseDecoder<>(new TypeSpec<>(TestRecord.class),
            new TypeSpec<>(String.class),
            Collections.<String, CompoundKey.TypeInfo>emptyMap(),
            null);

    final BatchKVResponse<String, EntityResponse<TestRecord>> response = decoder.wrapResponse(null, Collections.<String, String>emptyMap(), protocolVersion);
    Assert.assertNull(response);
  }