CssIdent

class CssIdent(val asStr: String) : CharSequence(source)

A simple inline class for wrapping String values that represent a CSS Identifier.

By wrapping this concept in an outer class, we can add extension methods for it instead of String. We also perform some checks in the constructor to ensure the passed in identifier is valid.

Constructors

Link copied to clipboard
constructor(asStr: String)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
Link copied to clipboard
open override val length: Int

Functions

Link copied to clipboard
open operator override fun get(index: Int): Char
Link copied to clipboard
fun renamed(action: String.() -> String): CssIdent

Convenience method for creating a new CssIdent based on this current one.

Link copied to clipboard
open override fun subSequence(startIndex: Int, endIndex: Int): CharSequence