cassandra-util-0.16.5: Cassandra Utilities
Safe HaskellSafe-Inferred
LanguageGHC2021

Cassandra.Helpers

Synopsis

Documentation

toOptionFieldName :: Options Source #

Convenient helper to convert record field names to use as YAML fields. NOTE: We typically use this for options in the configuration files! If you are looking into converting record field name to JSON to be used over the API, look for toJSONFieldName in the Data.Json.Util module. It converts field names into snake_case

Example: newtype TeamName = TeamName { teamName :: Text } deriveJSON toJSONFieldName ''teamName

would generate {To/From}JSON instances where the field name is "teamName"