Cassandra\Schema::keyspace PHP Метод

keyspace() публичный Метод

Returns a Keyspace instance by name.
public keyspace ( string $name ) : Cassandra\Keyspace
$name string Name of the keyspace to get
Результат Cassandra\Keyspace Keyspace instance or null
    function keyspace($name);

Usage Example

 /**
  * Schema metadata support is available; basic test.
  *
  * This test will ensure that the PHP driver supports schema metadata.
  */
 public function testBasicSchemaMetadata()
 {
     // Ensure the test class session connection has schema metadata
     $this->assertGreaterThan(0, count($this->schema));
     // Ensure the test class session contains the test keyspace
     $this->assertArrayHasKey($this->keyspaceName, $this->schema->keyspaces());
     $keyspace = $this->schema->keyspace($this->keyspaceName);
 }