Class NamingFolio
java.lang.Object
io.nosqlbench.cqlgen.binders.NamingFolio
The purpose of this class is to put all the logic/complexity of name condensing into one place.
Basically if you have identifiers that are globally unique within the active namespace,
WITHOUT using fully qualified names, then it is easier for users to use short names.
For example, if you have a column named "score" which is used as an int in one table and as
a double in another, then you must include the type information to provide two distinct identifiers
for the purpose of mapping bindings.
This will be a pre-built inverted index of all field which need to have bindings assigned.
A field reference is presumed to be unique within the scope from which the traversal to
the working set has a single path.
// name -> type -> table -> keyspace -> namespace
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddFieldRef(String column, String typedef, String table, String keyspace) voidaddFieldRef(Map<String, String> labels) getNames()voidnameFor(NBLabeledElement labeled, String... fields) This will eventually elide extraneous fields according to knowledge of all known names by name, type, table, keyspace.nameFor(NBLabeledElement labeled, Map<String, String> fields)
-
Field Details
-
DEFAULT_NAMER_SPEC
- See Also:
-
-
Constructor Details
-
NamingFolio
-
NamingFolio
public NamingFolio()
-
-
Method Details
-
addFieldRef
-
addFieldRef
-
nameFor
This will eventually elide extraneous fields according to knowledge of all known names by name, type, table, keyspace. For now it just returns everything in fully qualified form. -
nameFor
-
informNamerOfAllKnownNames
-
getNames
-