Digger protocol (digger v3.1.0)
Copy MarkdownDocumentation for Digger Protocol
Summary
Functions
'Atomize' a valid Types.data_type according to the protocol implementation
Camel case a valid Types.data_type according to the protocol implementation
'Dasherize' a valid Types.data_type according to the protocol implementation
Lower case first letter of a valid Types.data_type according to the protocol implementation
snake_case a valid Types.data_type according to the protocol implementation
'Stringify' a valid Types.data_type according to the protocol implementation
Upper case the first letter of a valid Types.data_type according to the protocol implementation
Types
@type t() :: term()
All the types that implement this protocol.
Functions
@spec atomize( Digger.Types.data_type(), keyword() ) :: Digger.Types.valid_return_type()
'Atomize' a valid Types.data_type according to the protocol implementation
By default, atomizing a string that has no corresponding existing atom
creates a new one via String.to_atom/1, which is safe for trusted input
but can exhaust the atom table if used on untrusted/external data (atoms
are never garbage collected).
Pass existing: true to atomize via String.to_existing_atom/1 instead:
strings that already have a matching atom are converted as usual, and
strings that don't are left as the original string rather than raising or
creating a new atom.
@spec camel_case( Digger.Types.data_type(), keyword() ) :: Digger.Types.valid_return_type()
Camel case a valid Types.data_type according to the protocol implementation
@spec dasherize( Digger.Types.data_type(), keyword() ) :: Digger.Types.valid_return_type()
'Dasherize' a valid Types.data_type according to the protocol implementation
@spec lowercase_first( Digger.Types.data_type(), keyword() ) :: Digger.Types.valid_return_type()
Lower case first letter of a valid Types.data_type according to the protocol implementation
@spec snake_case( Digger.Types.data_type(), keyword() ) :: Digger.Types.valid_return_type()
snake_case a valid Types.data_type according to the protocol implementation
@spec stringify( Digger.Types.data_type(), keyword() ) :: Digger.Types.valid_return_type()
'Stringify' a valid Types.data_type according to the protocol implementation
@spec upcase_first( Digger.Types.data_type(), keyword() ) :: Digger.Types.valid_return_type()
Upper case the first letter of a valid Types.data_type according to the protocol implementation