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

org.rocksdb.ByteBufferGetStatus Maven / Gradle / Ivy

Go to download

RocksDB fat jar that contains .so files for linux64, jnilib files for Mac OSX, and a .dll for Windows x64. It contains the Yamcs merge operator for the Parameter Archive

There is a newer version: 9.4.0.11
Show newest version
//  Copyright (c) Meta Platforms, Inc. and affiliates.
//
//  This source code is licensed under both the GPLv2 (found in the
//  COPYING file in the root directory) and Apache 2.0 License
//  (found in the LICENSE.Apache file in the root directory).

package org.rocksdb;

import java.nio.ByteBuffer;
import java.util.List;

/**
 * A ByteBuffer containing fetched data, together with a result for the fetch
 * and the total size of the object fetched.
 * 

* Used for the individual results of * {@link RocksDB#multiGetByteBuffers(List, List)} * {@link RocksDB#multiGetByteBuffers(List, List, List)} * {@link RocksDB#multiGetByteBuffers(ReadOptions, List, List)} * {@link RocksDB#multiGetByteBuffers(ReadOptions, List, List, List)} */ public class ByteBufferGetStatus { public final Status status; public final int requiredSize; public final ByteBuffer value; /** * Constructor used for success status, when the value is contained in the buffer * * @param status the status of the request to fetch into the buffer * @param requiredSize the size of the data, which may be bigger than the buffer * @param value the buffer containing as much of the value as fits */ ByteBufferGetStatus(final Status status, final int requiredSize, final ByteBuffer value) { this.status = status; this.requiredSize = requiredSize; this.value = value; } /** * Constructor used for a failure status, when no value is filled in * * @param status the status of the request to fetch into the buffer */ @SuppressWarnings("PMD.NullAssignment") ByteBufferGetStatus(final Status status) { this.status = status; this.requiredSize = 0; this.value = null; } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy