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

io.stargate.db.SimpleStatement Maven / Gradle / Ivy

There is a newer version: 2.1.0-BETA-19
Show newest version
package io.stargate.db;

import java.nio.ByteBuffer;
import java.util.Collections;
import java.util.List;
import javax.annotation.Nullable;

public class SimpleStatement extends Statement {
  private final String query;

  public SimpleStatement(String query, List values, @Nullable List boundNames) {
    super(values, boundNames);
    this.query = query;
  }

  public SimpleStatement(String query, List values) {
    this(query, values, null);
  }

  public SimpleStatement(String query) {
    this(query, Collections.emptyList());
  }

  public String queryString() {
    return query;
  }

  @Override
  public String toString() {
    return String.format("%s (with %d values)", query, values().size());
  }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy