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

com.julienviet.reactivex.pgclient.Tuple Maven / Gradle / Ivy

/*
 * Copyright 2014 Red Hat, Inc.
 *
 * Red Hat licenses this file to you under the Apache License, version 2.0
 * (the "License"); you may not use this file except in compliance with the
 * License.  You may obtain a copy of the License at:
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
 * License for the specific language governing permissions and limitations
 * under the License.
 */

package com.julienviet.reactivex.pgclient;

import java.util.Map;
import io.reactivex.Observable;
import io.reactivex.Flowable;
import io.reactivex.Single;
import io.reactivex.Completable;
import io.reactivex.Maybe;
import io.vertx.core.json.JsonArray;
import io.vertx.reactivex.core.buffer.Buffer;
import io.vertx.core.json.JsonObject;

/**
 * A general purpose tuple.
 *
 * 

* NOTE: This class has been automatically generated from the {@link com.julienviet.pgclient.Tuple original} non RX-ified interface using Vert.x codegen. */ @io.vertx.lang.reactivex.RxGen(com.julienviet.pgclient.Tuple.class) public class Tuple { public static final io.vertx.lang.reactivex.TypeArg __TYPE_ARG = new io.vertx.lang.reactivex.TypeArg<>( obj -> new Tuple((com.julienviet.pgclient.Tuple) obj), Tuple::getDelegate ); private final com.julienviet.pgclient.Tuple delegate; public Tuple(com.julienviet.pgclient.Tuple delegate) { this.delegate = delegate; } public com.julienviet.pgclient.Tuple getDelegate() { return delegate; } /** * @return a new empty tuple */ public static Tuple tuple() { Tuple ret = Tuple.newInstance(com.julienviet.pgclient.Tuple.tuple()); return ret; } /** * Create a tuple of one element. * @param elt1 the first value * @return the tuple */ public static Tuple of(Object elt1) { Tuple ret = Tuple.newInstance(com.julienviet.pgclient.Tuple.of(elt1)); return ret; } /** * Create a tuple of two elements. * @param elt1 the first value * @param elt2 the second value * @return the tuple */ public static Tuple of(Object elt1, Object elt2) { Tuple ret = Tuple.newInstance(com.julienviet.pgclient.Tuple.of(elt1, elt2)); return ret; } /** * Create a tuple of three elements. * @param elt1 the first value * @param elt2 the second value * @param elt3 the third value * @return the tuple */ public static Tuple of(Object elt1, Object elt2, Object elt3) { Tuple ret = Tuple.newInstance(com.julienviet.pgclient.Tuple.of(elt1, elt2, elt3)); return ret; } /** * Create a tuple of four elements. * @param elt1 the first value * @param elt2 the second value * @param elt3 the third value * @param elt4 the fourth value * @return the tuple */ public static Tuple of(Object elt1, Object elt2, Object elt3, Object elt4) { Tuple ret = Tuple.newInstance(com.julienviet.pgclient.Tuple.of(elt1, elt2, elt3, elt4)); return ret; } /** * Create a tuple of five elements. * @param elt1 the first value * @param elt2 the second value * @param elt3 the third value * @param elt4 the fourth value * @param elt5 the fifth value * @return the tuple */ public static Tuple of(Object elt1, Object elt2, Object elt3, Object elt4, Object elt5) { Tuple ret = Tuple.newInstance(com.julienviet.pgclient.Tuple.of(elt1, elt2, elt3, elt4, elt5)); return ret; } /** * Create a tuple of six elements. * @param elt1 the first value * @param elt2 the second value * @param elt3 the third value * @param elt4 the fourth value * @param elt5 the sixth value * @param elt6 * @return the tuple */ public static Tuple of(Object elt1, Object elt2, Object elt3, Object elt4, Object elt5, Object elt6) { Tuple ret = Tuple.newInstance(com.julienviet.pgclient.Tuple.of(elt1, elt2, elt3, elt4, elt5, elt6)); return ret; } /** * Get a boolean value at pos. * @param pos the position * @return the value or null */ public Boolean getBoolean(int pos) { Boolean ret = delegate.getBoolean(pos); return ret; } /** * Get an object value at pos. * @param pos the position * @return the value or null */ public Object getValue(int pos) { Object ret = (Object) delegate.getValue(pos); return ret; } /** * Get an integer value at pos. * @param pos the position * @return the value or null */ public Integer getInteger(int pos) { Integer ret = delegate.getInteger(pos); return ret; } /** * Get a long value at pos. * @param pos the position * @return the value or null */ public Long getLong(int pos) { Long ret = delegate.getLong(pos); return ret; } /** * Get a float value at pos. * @param pos the position * @return the value or null */ public Float getFloat(int pos) { Float ret = delegate.getFloat(pos); return ret; } /** * Get a double value at pos. * @param pos the position * @return the value or null */ public Double getDouble(int pos) { Double ret = delegate.getDouble(pos); return ret; } /** * Get a string value at pos. * @param pos the position * @return the value or null */ public String getString(int pos) { String ret = delegate.getString(pos); return ret; } /** * Get a {@link java.lang.Character} value at pos. * @param pos the position * @return the value or null */ public Character getCharacter(int pos) { Character ret = delegate.getCharacter(pos); return ret; } /** * Get a json object value at pos. * @param pos the position * @return the value or null */ public JsonObject getJsonObject(int pos) { JsonObject ret = delegate.getJsonObject(pos); return ret; } /** * Get a json array value at pos. * @param pos the position * @return the value or null */ public JsonArray getJsonArray(int pos) { JsonArray ret = delegate.getJsonArray(pos); return ret; } /** * Get a buffer value at pos. * @param pos the position * @return the value or null */ public Buffer getBuffer(int pos) { Buffer ret = Buffer.newInstance(delegate.getBuffer(pos)); return ret; } /** * Add a boolean value at the end of the tuple. * @param value the value * @return a reference to this, so the API can be used fluently */ public Tuple addBoolean(Boolean value) { delegate.addBoolean(value); return this; } /** * Add an object value at the end of the tuple. * @param value the value * @return a reference to this, so the API can be used fluently */ public Tuple addValue(Object value) { delegate.addValue(value); return this; } /** * Add an integer value at the end of the tuple. * @param value the value * @return a reference to this, so the API can be used fluently */ public Tuple addInteger(Integer value) { delegate.addInteger(value); return this; } /** * Add a long value at the end of the tuple. * @param value the value * @return a reference to this, so the API can be used fluently */ public Tuple addLong(Long value) { delegate.addLong(value); return this; } /** * Add a float value at the end of the tuple. * @param value the value * @return a reference to this, so the API can be used fluently */ public Tuple addFloat(Float value) { delegate.addFloat(value); return this; } /** * Add a double value at the end of the tuple. * @param value the value * @return a reference to this, so the API can be used fluently */ public Tuple addDouble(Double value) { delegate.addDouble(value); return this; } /** * Add a string value at the end of the tuple. * @param value the value * @return a reference to this, so the API can be used fluently */ public Tuple addString(String value) { delegate.addString(value); return this; } /** * Add a {@link java.lang.Character} value at the end of the tuple. * @param value the value * @return a reference to this, so the API can be used fluently */ public Tuple addCharacter(Character value) { delegate.addCharacter(value); return this; } /** * Add a json object value at the end of the tuple. * @param value the value * @return a reference to this, so the API can be used fluently */ public Tuple addJsonObject(JsonObject value) { delegate.addJsonObject(value); return this; } /** * Add a json array value at the end of the tuple. * @param value the value * @return a reference to this, so the API can be used fluently */ public Tuple addJsonArray(JsonArray value) { delegate.addJsonArray(value); return this; } /** * Add a buffer value at the end of the tuple. * @param value the value * @return a reference to this, so the API can be used fluently */ public Tuple addBuffer(Buffer value) { delegate.addBuffer(value.getDelegate()); return this; } /** * @return the tuple size */ public int size() { int ret = delegate.size(); return ret; } public static Tuple newInstance(com.julienviet.pgclient.Tuple arg) { return arg != null ? new Tuple(arg) : null; } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy