public class CassandraMapping extends Object
Modifier and Type | Field and Description |
---|---|
static String |
DEFAULT_COLUMNS_TTL |
static int |
DEFAULT_GCGRACE_SECONDS |
static org.slf4j.Logger |
LOG |
Constructor and Description |
---|
CassandraMapping(org.jdom.Element keyspace,
org.jdom.Element mapping)
Primary class for loading Cassandra configuration from the 'MAPPING_FILE'.
|
Modifier and Type | Method and Description |
---|---|
void |
addColumn(String pFamilyName,
String pFieldName,
String pColumnName)
Add new column to the CassandraMapping using the the below parameters
|
String |
getClusterName()
Simply gets the Cassandra cluster (the machines (nodes)
in a logical Cassandra instance) name.
|
String |
getColumn(String name) |
List<me.prettyprint.hector.api.ddl.ColumnFamilyDefinition> |
getColumnFamilyDefinitions() |
Map<String,String> |
getColumnsAttribs() |
String |
getFamily(String name) |
Map<String,String> |
getFamilyMap() |
String |
getHostName()
Simply gets the Cassandra host name.
|
String |
getKeyspaceName()
Simply gets the Cassandra namespace for ColumnFamilies, typically one per application
|
boolean |
isSuper(String family)
Read family super attribute.
|
public static final org.slf4j.Logger LOG
public static final String DEFAULT_COLUMNS_TTL
public static final int DEFAULT_GCGRACE_SECONDS
public CassandraMapping(org.jdom.Element keyspace, org.jdom.Element mapping)
public String getHostName()
public String getClusterName()
public String getKeyspaceName()
public void addColumn(String pFamilyName, String pFieldName, String pColumnName)
pFamilyName
- the column family namepFieldName
- the Avro field from the SchemapColumnName
- the column name within the column family.public boolean isSuper(String family)
family
- the family namepublic List<me.prettyprint.hector.api.ddl.ColumnFamilyDefinition> getColumnFamilyDefinitions()
Copyright © 2010-2014 The Apache Software Foundation. All Rights Reserved.