All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.noenv.wiremongo.mapping.find.FindOneAndUpdateBase Maven / Gradle / Ivy

There is a newer version: 4.5.10
Show newest version
package com.noenv.wiremongo.mapping.find;

import com.noenv.wiremongo.command.find.FindOneAndUpdateBaseCommand;
import com.noenv.wiremongo.mapping.update.WithUpdate;
import io.vertx.core.json.JsonObject;

@SuppressWarnings("squid:MaximumInheritanceDepth")
public abstract class FindOneAndUpdateBase> extends WithUpdate {

  public FindOneAndUpdateBase() {
    this("findOneAndUpdate");
  }

  public FindOneAndUpdateBase(String method) {
    super(method);
  }

  public FindOneAndUpdateBase(JsonObject json) {
    super(json);
  }

  @Override
  public C returns(final JsonObject response) {
    return super.stub(c -> null == response ? null : response.copy());
  }

  @Override
  protected JsonObject parseResponse(Object jsonValue) {
    return (JsonObject) jsonValue;
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy