Package-level declarations

Types

Link copied to clipboard
abstract class BaseStringNotation(splitAt: Regex) : StringNotation

Base class for implementing string notations.

Link copied to clipboard

A notation for static final fields in Java. This notation is like ScreamingSnakeCase, but when printing, it will drop any character that is not allowed in a Java identifier. If the result is a Java keyword, _ will be appended to it.

Link copied to clipboard

A notation for java member names. This notation is like LowerCamelCase, but when printing, it will drop any character that is not allowed in a Java identifier. If the result is a Java keyword, _ will be appended to it.

Link copied to clipboard

A notation for whole java packages. When printing parts, it will drop any character that is not allowed in a Java identifier. If the result is a Java keyword, _ will be appended to it.

Link copied to clipboard

A notation for java package parts. When printing, it simply concatenates all word parts and drops any character that is not allowed in a Java identifier. If the result is a Java keyword, _ will be appended to it. When parsing, the notation will recognise word parts both in the LowerCamelCase and the SnakeCase notation. However, neither notation is conventional and parsing will usually yield only one word part on real-world inputs.

Link copied to clipboard

A notation for Java type names. This notation is like UpperCamelCase, but when printing, it will drop any character that is not allowed in a Java identifier. If the result is a Java keyword, _ will be appended to it.

Link copied to clipboard

The lowerCamelCase notation.

Link copied to clipboard

Notation for words written like in normal language. Parsing will recognise all substrings that are separated by one or more characters of whitespace as a part. Printing will print the parts separated by one space.

Link copied to clipboard

The SCREAMING_SNAKE_CASE notation.

Link copied to clipboard

The snake_case notation.

Link copied to clipboard
interface StringNotation

A convention for representing Words.

Link copied to clipboard

A notation for paths on a Unix file system. Parsing will recognise all substrings that are separated by / as a part. Printing will print the parts separated by / after removing \u0000 (ASCII: NUL) and \u0057 (ASCII: slash) characters from them.

Link copied to clipboard

The UpperCamelCase notation.

Link copied to clipboard

A notation for paths on a Windows file system. Parsing will recognise all substrings that are separated by \ as a part. Printing will print the parts separated by \ after removing the following characters from them:

Link copied to clipboard
class Word(val parts: Sequence<String>)

A notation-agnostic representation of a string. This is a “word” in the sense of “word over the Unicode alphabet”, not in the sense of a word in any spoken language. A Word consists of parts.

Functions

Link copied to clipboard

Converts this string, into a Word according to the provided notation. This method expects that the input is formatted according to the notation and creates a notation-agnostic representation of it.