Package io.github.mfvanek.pg.model.index
Class IndexWithSize
- java.lang.Object
-
- io.github.mfvanek.pg.model.index.Index
-
- io.github.mfvanek.pg.model.index.IndexWithSize
-
- All Implemented Interfaces:
IndexNameAware
,IndexSizeAware
,TableNameAware
,java.lang.Comparable<Index>
- Direct Known Subclasses:
IndexWithBloat
,IndexWithNulls
,UnusedIndex
@Immutable public class IndexWithSize extends Index implements IndexSizeAware
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
IndexWithSize(java.lang.String tableName, java.lang.String indexName, long indexSizeInBytes)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description long
getIndexSizeInBytes()
Gets index size in bytes.protected java.lang.String
innerToString()
static IndexWithSize
of(java.lang.String tableName, java.lang.String indexName, long indexSizeInBytes)
java.lang.String
toString()
-
Methods inherited from class io.github.mfvanek.pg.model.index.Index
compareTo, equals, getIndexName, getTableName, hashCode, of
-
-
-
-
Method Detail
-
getIndexSizeInBytes
public long getIndexSizeInBytes()
Gets index size in bytes.- Specified by:
getIndexSizeInBytes
in interfaceIndexSizeAware
- Returns:
- index size in bytes
-
innerToString
protected java.lang.String innerToString()
- Overrides:
innerToString
in classIndex
-
of
public static IndexWithSize of(@Nonnull java.lang.String tableName, @Nonnull java.lang.String indexName, long indexSizeInBytes)
-
-