public DataRetrievalRule unmarshall(JsonUnmarshallerContext context) throws Exception {
    DataRetrievalRule dataRetrievalRule = new DataRetrievalRule();

    int originalDepth = context.getCurrentDepth();
    String currentParentElement = context.getCurrentParentElement();
    int targetDepth = originalDepth + 1;

    JsonToken token = context.getCurrentToken();
    if (token == null) token = context.nextToken();
    if (token == VALUE_NULL) return null;

    while (true) {
      if (token == null) break;

      if (token == FIELD_NAME || token == START_OBJECT) {
        if (context.testExpression("Strategy", targetDepth)) {
          context.nextToken();
          dataRetrievalRule.setStrategy(StringJsonUnmarshaller.getInstance().unmarshall(context));
        }
        if (context.testExpression("BytesPerHour", targetDepth)) {
          context.nextToken();
          dataRetrievalRule.setBytesPerHour(LongJsonUnmarshaller.getInstance().unmarshall(context));
        }
      } else if (token == END_ARRAY || token == END_OBJECT) {
        if (context.getLastParsedParentElement() == null
            || context.getLastParsedParentElement().equals(currentParentElement)) {
          if (context.getCurrentDepth() <= originalDepth) break;
        }
      }

      token = context.nextToken();
    }

    return dataRetrievalRule;
  }
  public ListPartsResult unmarshall(JsonUnmarshallerContext context) throws Exception {
    ListPartsResult listPartsResult = new ListPartsResult();

    int originalDepth = context.getCurrentDepth();
    String currentParentElement = context.getCurrentParentElement();
    int targetDepth = originalDepth + 1;

    JsonToken token = context.getCurrentToken();
    if (token == null) token = context.nextToken();
    if (token == VALUE_NULL) return null;

    while (true) {
      if (token == null) break;

      if (token == FIELD_NAME || token == START_OBJECT) {
        if (context.testExpression("MultipartUploadId", targetDepth)) {
          context.nextToken();
          listPartsResult.setMultipartUploadId(
              StringJsonUnmarshaller.getInstance().unmarshall(context));
        }
        if (context.testExpression("VaultARN", targetDepth)) {
          context.nextToken();
          listPartsResult.setVaultARN(StringJsonUnmarshaller.getInstance().unmarshall(context));
        }
        if (context.testExpression("ArchiveDescription", targetDepth)) {
          context.nextToken();
          listPartsResult.setArchiveDescription(
              StringJsonUnmarshaller.getInstance().unmarshall(context));
        }
        if (context.testExpression("PartSizeInBytes", targetDepth)) {
          context.nextToken();
          listPartsResult.setPartSizeInBytes(
              LongJsonUnmarshaller.getInstance().unmarshall(context));
        }
        if (context.testExpression("CreationDate", targetDepth)) {
          context.nextToken();
          listPartsResult.setCreationDate(StringJsonUnmarshaller.getInstance().unmarshall(context));
        }
        if (context.testExpression("Parts", targetDepth)) {
          context.nextToken();
          listPartsResult.setParts(
              new ListUnmarshaller<PartListElement>(PartListElementJsonUnmarshaller.getInstance())
                  .unmarshall(context));
        }
        if (context.testExpression("Marker", targetDepth)) {
          context.nextToken();
          listPartsResult.setMarker(StringJsonUnmarshaller.getInstance().unmarshall(context));
        }
      } else if (token == END_ARRAY || token == END_OBJECT) {
        if (context.getLastParsedParentElement() == null
            || context.getLastParsedParentElement().equals(currentParentElement)) {
          if (context.getCurrentDepth() <= originalDepth) break;
        }
      }

      token = context.nextToken();
    }

    return listPartsResult;
  }
  public VaultAccessPolicy unmarshall(JsonUnmarshallerContext context) throws Exception {
    VaultAccessPolicy vaultAccessPolicy = new VaultAccessPolicy();

    int originalDepth = context.getCurrentDepth();
    String currentParentElement = context.getCurrentParentElement();
    int targetDepth = originalDepth + 1;

    JsonToken token = context.getCurrentToken();
    if (token == null) token = context.nextToken();
    if (token == VALUE_NULL) return null;

    while (true) {
      if (token == null) break;

      if (token == FIELD_NAME || token == START_OBJECT) {
        if (context.testExpression("Policy", targetDepth)) {
          context.nextToken();
          vaultAccessPolicy.setPolicy(StringJsonUnmarshaller.getInstance().unmarshall(context));
        }
      } else if (token == END_ARRAY || token == END_OBJECT) {
        if (context.getLastParsedParentElement() == null
            || context.getLastParsedParentElement().equals(currentParentElement)) {
          if (context.getCurrentDepth() <= originalDepth) break;
        }
      }

      token = context.nextToken();
    }

    return vaultAccessPolicy;
  }