Class KeyspaceMetadata
Inheritance
Inherited Members
Namespace: Dse
Assembly: Dse.dll
Syntax
public class KeyspaceMetadata
Properties
DurableWrites
Gets a value indicating whether durable writes are set on this keyspace.
Declaration
public bool DurableWrites { get; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
|
IsVirtual
Determines whether the keyspace is a virtual keyspace or not.
Declaration
public bool IsVirtual { get; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
Name
Gets the name of this keyspace.
Declaration
public string Name { get; }
Property Value
| Type | Description |
|---|---|
| System.String | the name of this CQL keyspace. |
Replication
Returns the replication options for this keyspace.
Declaration
public IDictionary<string, int> Replication { get; }
Property Value
| Type | Description |
|---|---|
| System.Collections.Generic.IDictionary<System.String, System.Int32> | a dictionary containing the keyspace replication strategy options. |
StrategyClass
Gets the Strategy Class of this keyspace.
Declaration
public string StrategyClass { get; }
Property Value
| Type | Description |
|---|---|
| System.String | name of StrategyClass of this keyspace. |
Methods
AsCqlQuery()
Returns a CQL query representing this keyspace. This method returns a single 'CREATE KEYSPACE' query with the options corresponding to this name definition.
Declaration
public string AsCqlQuery()
Returns
| Type | Description |
|---|---|
| System.String | the 'CREATE KEYSPACE' query corresponding to this name.
|
ExportAsString()
Return a String containing CQL queries representing this
name and the table it contains. In other words, this method returns the
queries that would allow to recreate the schema of this name, along with
all its table. Note that the returned String is formatted to be human
readable (for some definition of human readable at least).
Declaration
public string ExportAsString()
Returns
| Type | Description |
|---|---|
| System.String | the CQL queries representing this name schema as a code String}. |
GetAggregate(String, String[])
Gets a CQL aggregate by name and signature
Declaration
public AggregateMetadata GetAggregate(string aggregateName, string[] signature)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | aggregateName | |
| System.String[] | signature |
Returns
| Type | Description |
|---|---|
| AggregateMetadata | The aggregate metadata or null if not found. |
GetFunction(String, String[])
Gets a CQL function by name and signature
Declaration
public FunctionMetadata GetFunction(string functionName, string[] signature)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | functionName | |
| System.String[] | signature |
Returns
| Type | Description |
|---|---|
| FunctionMetadata | The function metadata or null if not found. |
GetMaterializedViewMetadata(String)
Returns metadata of specified view in this keyspace.
Declaration
public MaterializedViewMetadata GetMaterializedViewMetadata(string viewName)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | viewName | the name of view to retrieve |
Returns
| Type | Description |
|---|---|
| MaterializedViewMetadata | the metadata for view |
GetTableMetadata(String)
Returns metadata of specified table in this keyspace.
Declaration
public TableMetadata GetTableMetadata(string tableName)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | tableName | the name of table to retrieve |
Returns
| Type | Description |
|---|---|
| TableMetadata | the metadata for table |
GetTablesMetadata()
Returns metadata of all tables defined in this keyspace.
Declaration
public IEnumerable<TableMetadata> GetTablesMetadata()
Returns
| Type | Description |
|---|---|
| System.Collections.Generic.IEnumerable<TableMetadata> | an IEnumerable of TableMetadata for the tables defined in this keyspace. |
GetTablesNames()
Returns names of all tables defined in this keyspace.
Declaration
public ICollection<string> GetTablesNames()
Returns
| Type | Description |
|---|---|
| System.Collections.Generic.ICollection<System.String> | a collection of all, defined in this keyspace tables names. |