public class BasicVersionedMetadata extends Object implements VersionedMetadata
VersionedMetadata,
BuiltInFunctionsMetadataBuilder| Constructor and Description |
|---|
BasicVersionedMetadata(String metadataName)
Constructs a database metadata valid in any version of Cassandra.
|
BasicVersionedMetadata(String metadataName,
Function<CassandraConnection,Boolean> additionalCondition)
Constructs a database metadata valid from the specified version of Cassandra and verifying a specific condition
for the current connection.
|
BasicVersionedMetadata(String metadataName,
String validFrom)
Constructs a database metadata valid from the specified version of Cassandra.
|
BasicVersionedMetadata(String metadataName,
String validFrom,
Function<CassandraConnection,Boolean> additionalCondition)
Constructs a database metadata valid from the specified version of Cassandra and verifying a specific condition
for the current connection.
|
BasicVersionedMetadata(String metadataName,
String validFrom,
String invalidFrom)
Constructs a database metadata valid in the specified range of Cassandra versions.
|
BasicVersionedMetadata(String metadataName,
String validFrom,
String invalidFrom,
Function<CassandraConnection,Boolean> additionalCondition)
Constructs a database metadata valid in the specified range of Cassandra versions and verifying a specific
condition for the current connection.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
fulfillAdditionalCondition(CassandraConnection connection)
Checks if the connection to the database fulfills some specific conditions defined in the implementation of
VersionedMetadata. |
String |
getName()
Gets the metadata name (for example a CQL keyword, or a built-in function name).
|
org.semver4j.Semver |
isInvalidFrom()
Gets the first Cassandra version in which the metadata does not exist anymore.
|
org.semver4j.Semver |
isValidFrom()
Gets the minimal Cassandra version from which the metadata exists.
|
public BasicVersionedMetadata(String metadataName, String validFrom, String invalidFrom, Function<CassandraConnection,Boolean> additionalCondition)
metadataName - The metadata name (a built-in function name for example).validFrom - The minimal Cassandra version from which the metadata exists. If null, we
consider the metadata exists in any version of the Cassandra database.invalidFrom - The first Cassandra version in which the metadata does not exist anymore. If
null, we consider the metadata exists in any version of the Cassandra
database greater than validFrom.additionalCondition - An additional condition to verify on the current connection to the database.public BasicVersionedMetadata(String metadataName, String validFrom, String invalidFrom)
metadataName - The metadata name (a built-in function name for example).validFrom - The minimal Cassandra version from which the metadata exists. If null, we consider
the metadata exists in any version of the Cassandra database.invalidFrom - The first Cassandra version in which the metadata does not exist anymore. If null,
we consider the metadata exists in any version of the Cassandra database greater than
validFrom.public BasicVersionedMetadata(String metadataName, String validFrom, Function<CassandraConnection,Boolean> additionalCondition)
metadataName - The metadata name (a built-in function name for example).validFrom - The minimal Cassandra version from which the metadata exists.additionalCondition - An additional condition to verify on the current connection to the database.public BasicVersionedMetadata(String metadataName, String validFrom)
metadataName - The metadata name (a built-in function name for example).validFrom - The minimal Cassandra version from which the metadata exists.public BasicVersionedMetadata(String metadataName, Function<CassandraConnection,Boolean> additionalCondition)
metadataName - The metadata name (a built-in function name for example).additionalCondition - An additional condition to verify on the current connection to the database.public BasicVersionedMetadata(String metadataName)
metadataName - The metadata name (a built-in function name for example).public String getName()
VersionedMetadatagetName in interface VersionedMetadatapublic org.semver4j.Semver isValidFrom()
VersionedMetadatanull, we consider the metadata
always existed.isValidFrom in interface VersionedMetadatanull.public org.semver4j.Semver isInvalidFrom()
VersionedMetadatanull, it means the
metadata still exists in the latest version of Cassandra.isInvalidFrom in interface VersionedMetadatanull.public boolean fulfillAdditionalCondition(CassandraConnection connection)
VersionedMetadataVersionedMetadata.fulfillAdditionalCondition in interface VersionedMetadataconnection - The connection to the database.true if the additional condition is verified by the connection, false otherwise.Copyright © 2020–2026 ING Bank. All rights reserved.