Package io.tiledb.java.api
Class FragmentInfo
- java.lang.Object
-
- io.tiledb.java.api.FragmentInfo
-
public class FragmentInfo extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description FragmentInfo(Context ctx, java.lang.String uri)
FragmentInfo(Context ctx, java.lang.String uri, EncryptionType encryptionType, java.lang.String key)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
dump()
Gets the URI of the fragment to vacuum with the given index.long
getCellNum(long fragmentID)
In the case of sparse fragments, this is the number of non-empty cells in the fragment.boolean
getDense(long fragmentID)
Returns true if the fragment with the given index is dense.long
getFragmentNum()
Returns the number of fragments.long
getFragmentSize(long fragmentID)
Returns the size of the fragment with the given index.java.lang.String
getFragmentURI(long fragmentID)
Returns the URI of the fragment with the given index.Pair
getNonEmptyDomainFromIndex(long fragmentID, long dimensionID)
Retrieves the non-empty domain from a given fragment for a given dimension name.Pair
getNonEmptyDomainFromName(long fragmentID, java.lang.String dimensionName)
Retrieves the non-empty domain from a given fragment for a given dimension name.Pair
getNonEmptyDomainVarFromIndex(long fragmentID, long dimensionID)
Retrieves the non-empty domain from a fragment for a given dimension index.Pair
getNonEmptyDomainVarFromName(long fragmentID, java.lang.String dimensionName)
Retrieves the non-empty domain from a fragment for a given dimension name.Pair<java.lang.Long,java.lang.Long>
getNonEmptyDomainVarSizeFromIndex(long fragmentID, long dimensionID)
Retrieves the non-empty domain range sizes from a fragment for a given dimension index.Pair<java.lang.Long,java.lang.Long>
getNonEmptyDomainVarSizeFromName(long fragmentID, java.lang.String dimensionName)
Retrieves the non-empty domain range sizes from a fragment for a given dimension name.boolean
getSparse(long fragmentID)
Returns true if the fragment with the given index is sparse.Pair<java.lang.Long,java.lang.Long>
getTimestampRange(long fragmentID)
Returns the timestamp range of the fragment with the given index.long
getToVacuumNum()
Gets the number of fragments to vacuum.java.lang.String
getToVacuumUri(long fragmentID)
Gets the URI of the fragment to vacuum with the given index.long
getUnconsolidatedMetadataNum()
Gets the number of fragments with unconsolidated metadata.long
getVersion(long fragmentID)
Retrieves the format version of a fragment.boolean
hasConsolidatedMetadata(long fragmentID)
Checks if a fragment has consolidated metadata.
-
-
-
Constructor Detail
-
FragmentInfo
public FragmentInfo(Context ctx, java.lang.String uri) throws TileDBError
- Parameters:
ctx
-uri
-- Throws:
TileDBError
-
FragmentInfo
public FragmentInfo(Context ctx, java.lang.String uri, EncryptionType encryptionType, java.lang.String key) throws TileDBError
- Parameters:
ctx
-uri
-key
- The encryption key- Throws:
TileDBError
-
-
Method Detail
-
getNonEmptyDomainVarSizeFromIndex
public Pair<java.lang.Long,java.lang.Long> getNonEmptyDomainVarSizeFromIndex(long fragmentID, long dimensionID) throws TileDBError
Retrieves the non-empty domain range sizes from a fragment for a given dimension index. Applicable to var-sized dimensions.- Parameters:
fragmentID
- The fragment IDdimensionID
- The dimension name- Returns:
- The non-empty domain range sizes from a fragment for a given dimension index.
- Throws:
TileDBError
-
getNonEmptyDomainVarSizeFromName
public Pair<java.lang.Long,java.lang.Long> getNonEmptyDomainVarSizeFromName(long fragmentID, java.lang.String dimensionName) throws TileDBError
Retrieves the non-empty domain range sizes from a fragment for a given dimension name. Applicable to var-sized dimensions.- Parameters:
fragmentID
- The fragment IDdimensionName
- The dimension name- Returns:
- The non-empty domain range sizes from a fragment for a given dimension name
- Throws:
TileDBError
-
getFragmentNum
public long getFragmentNum() throws TileDBError
Returns the number of fragments.- Returns:
- The number of fragments
- Throws:
TileDBError
-
getFragmentURI
public java.lang.String getFragmentURI(long fragmentID) throws TileDBError
Returns the URI of the fragment with the given index.- Parameters:
fragmentID
- The fragment ID- Returns:
- The fragment URI
- Throws:
TileDBError
-
getFragmentSize
public long getFragmentSize(long fragmentID) throws TileDBError
Returns the size of the fragment with the given index.- Parameters:
fragmentID
- The fragment ID- Returns:
- The fragment size
- Throws:
TileDBError
-
getDense
public boolean getDense(long fragmentID) throws TileDBError
Returns true if the fragment with the given index is dense.- Parameters:
fragmentID
- The fragment ID- Returns:
- True, if the fragment is dense, false otherwise
- Throws:
TileDBError
-
getSparse
public boolean getSparse(long fragmentID) throws TileDBError
Returns true if the fragment with the given index is sparse.- Parameters:
fragmentID
- The fragment ID- Returns:
- True if the fragment is sparse, false otherwise
- Throws:
TileDBError
-
getTimestampRange
public Pair<java.lang.Long,java.lang.Long> getTimestampRange(long fragmentID) throws TileDBError
Returns the timestamp range of the fragment with the given index.- Parameters:
fragmentID
- The fragment ID- Returns:
- A Pair including the timestamp range
- Throws:
TileDBError
-
getNonEmptyDomainFromIndex
public Pair getNonEmptyDomainFromIndex(long fragmentID, long dimensionID) throws TileDBError
Retrieves the non-empty domain from a given fragment for a given dimension name.- Parameters:
fragmentID
- The fragment IDdimensionID
- The dimension name- Returns:
- The non-empty domain of the given fragment and dimension ID
- Throws:
TileDBError
-
getNonEmptyDomainFromName
public Pair getNonEmptyDomainFromName(long fragmentID, java.lang.String dimensionName) throws TileDBError
Retrieves the non-empty domain from a given fragment for a given dimension name.- Parameters:
fragmentID
- The fragment IDdimensionName
- The dimension name- Returns:
- The non-empty domain of the given fragment ID and dimension name
- Throws:
TileDBError
-
getNonEmptyDomainVarFromIndex
public Pair getNonEmptyDomainVarFromIndex(long fragmentID, long dimensionID) throws TileDBError
Retrieves the non-empty domain from a fragment for a given dimension index. Applicable to var-sized dimensions.- Parameters:
fragmentID
- The fragment IDdimensionID
- The dimension ID- Returns:
- The non-empty domain given the fragment and dimension IDs
- Throws:
TileDBError
-
getNonEmptyDomainVarFromName
public Pair getNonEmptyDomainVarFromName(long fragmentID, java.lang.String dimensionName) throws TileDBError
Retrieves the non-empty domain from a fragment for a given dimension name. Applicable to var-sized dimensions.- Parameters:
fragmentID
- The fragment IDdimensionName
- The dimension name- Returns:
- The non-empty domain given the fragment ID and dimension name
- Throws:
TileDBError
-
getCellNum
public long getCellNum(long fragmentID) throws TileDBError
In the case of sparse fragments, this is the number of non-empty cells in the fragment.In the case of dense fragments, TileDB may add fill values to populate partially populated tiles. Those fill values are counted in the returned number of cells. In other words, the cell number is derived from the number of *integral* tiles written in the file.
- Parameters:
fragmentID
- The fragment ID- Returns:
- The number of cells
- Throws:
TileDBError
-
getVersion
public long getVersion(long fragmentID) throws TileDBError
Retrieves the format version of a fragment.- Parameters:
fragmentID
- The fragment ID- Returns:
- The version
- Throws:
TileDBError
-
hasConsolidatedMetadata
public boolean hasConsolidatedMetadata(long fragmentID) throws TileDBError
Checks if a fragment has consolidated metadata.- Parameters:
fragmentID
- The fragment ID- Returns:
- Throws:
TileDBError
-
getUnconsolidatedMetadataNum
public long getUnconsolidatedMetadataNum() throws TileDBError
Gets the number of fragments with unconsolidated metadata.- Returns:
- The number of fragments with unconsolidated metadata
- Throws:
TileDBError
-
getToVacuumNum
public long getToVacuumNum() throws TileDBError
Gets the number of fragments to vacuum.- Returns:
- The number of fragments to vacuum
- Throws:
TileDBError
-
getToVacuumUri
public java.lang.String getToVacuumUri(long fragmentID) throws TileDBError
Gets the URI of the fragment to vacuum with the given index.- Parameters:
fragmentID
- The fragment ID- Returns:
- The URI of the fragment to vacuum with the given index
- Throws:
TileDBError
-
dump
public java.lang.String dump() throws TileDBError
Gets the URI of the fragment to vacuum with the given index.- Returns:
- The URI of the fragment to vacuum with the given index
- Throws:
TileDBError
-
-