The cl-change-case Reference Manual

Table of Contents

Next: , Previous: , Up: (dir)   [Contents][Index]

The cl-change-case Reference Manual

This is the cl-change-case Reference Manual, version 0.1.0, generated automatically by Declt version 2.4 "Will Decker" on Wed Jun 20 11:01:27 2018 GMT+0.


Next: , Previous: , Up: Top   [Contents][Index]

1 Introduction

Build Status Coverage Status Quicklisp

NAME

cl-change-case — Convert strings between camelCase, param-case, PascalCase and more

VERSION

Version 0.1.0

SYNOPSIS

(use-package :cl-change-case)

(format t "~{~S~%~}"
        (list (camel-case "test string")
              (param-case "test string")
              (pascal-case "test string")))

DESCRIPTION

cl-change-case is library to convert strings between camelCase, PascalCase, snake_case, param-case, CONSTANT_CASE and more.

This is a Common Lisp port of blakeembrey/change-case released under The MIT License.

Functions

lower-case

Return the string in lower case.

(lower-case "TEST STRING")

"test string"

lower-case-first

Lower case of the first character of string.

(lower-case-first "TEST STRING")

"tEST STRING"

string-lower-case-p

Test if all characters in string have lower case.

(string-lower-case-p "test string")

T

upper-case

Return the string in upper case.

(upper-case "test string")

"TEST STRING"

upper-case-first

Upper case the first character of string.

(upper-case-first "test string")

"Test string"

string-upper-case-p

Test if all characters in string have upper case.

(string-upper-case-p "TEST STRING")

T

no-case

Make string a lower case, space separated string.

(no-case "test_stringTest")

"test string test"

Optionally you can provide a different replacement string.

(no-case "test_stringTest" :replacement "$$")

"test$$string$$test"

camel-case

Convert string to camelCase.

(camel-case "test_string")

"testString"

dot-case

Convert string to dot.case.

(dot-case "Test String")

"test.string"

header-case

Title case string but dash separated.

(header-case "test string")

"Test-String"

param-case

Convert string to param-case.

(param-case "test string")

"test-string"

pascal-case

Convert string to PascalCase.

(pascal-case "test string")

"TestString"

path-case

Convert string to path/case.

(path-case "test string more")

"test/string/more"

sentence-case

Makes string a lower case, space separated string with the first word capitalized.

(sentence-case "thisIsATestString")

"This is a test string"

snake-case

Convert string to snake_case.

(snake-case "test string")

"test_string"

swap-case

Reverse the case of each character in string.

(swap-case "PascalCase")

"pASCALcASE"

title-case

Make string space separated with each word capitalized.

(title-case "this_is a_test_string")

"This Is A Test String"

constant-case

Convert string to CONSTANT_CASE.

(constant-case "test string")

"TEST_STRING"

AUTHOR

Sebastian Christ (rudolfo.christ@gmail.com)

COPYRIGHT

Copyright (c) 2016 Sebastian Christ (rudolfo.christ@gmail.com)

Released under the LLGPL license.

SEE ALSO


Next: , Previous: , Up: Top   [Contents][Index]

2 Systems

The main system appears first, followed by any subsystem dependency.


Previous: , Up: Systems   [Contents][Index]

2.1 cl-change-case

Author

Sebastian Christ

Contact

rudolfo.christ@gmail.com

Source Control

(:git "git@github.com:rudolfochrist/cl-change-case.git")

Bug Tracker

https://github.com/rudolfochrist/cl-change-case/issues

License

LLGPL

Description

Convert strings between camelCase, param-case, PascalCase and more

Version

0.1.0

Dependencies
Source

cl-change-case.asd (file)

Component

src (module)


Next: , Previous: , Up: Top   [Contents][Index]

3 Modules

Modules are listed depth-first from the system components tree.


Previous: , Up: Modules   [Contents][Index]

3.1 cl-change-case/src

Parent

cl-change-case (system)

Location

src/

Component

cl-change-case.lisp (file)


Next: , Previous: , Up: Top   [Contents][Index]

4 Files

Files are sorted by type and then listed depth-first from the systems components trees.


Previous: , Up: Files   [Contents][Index]

4.1 Lisp


Next: , Previous: , Up: Lisp files   [Contents][Index]

4.1.1 cl-change-case.asd

Location

cl-change-case.asd

Systems

cl-change-case (system)


Previous: , Up: Lisp files   [Contents][Index]

4.1.2 cl-change-case/src/cl-change-case.lisp

Parent

src (module)

Location

src/cl-change-case.lisp

Packages

cl-change-case

Exported Definitions
Internal Definitions

+empty-string+ (constant)


Next: , Previous: , Up: Top   [Contents][Index]

5 Packages

Packages are listed by definition order.


Previous: , Up: Packages   [Contents][Index]

5.1 cl-change-case

Source

cl-change-case.lisp (file)

Nickname

change-case

Use List

common-lisp

Exported Definitions
Internal Definitions

+empty-string+ (constant)


Next: , Previous: , Up: Top   [Contents][Index]

6 Definitions

Definitions are sorted by export status, category, package, and then by lexicographic order.


Next: , Previous: , Up: Definitions   [Contents][Index]

6.1 Exported definitions


Previous: , Up: Exported definitions   [Contents][Index]

6.1.1 Functions

Function: camel-case STRING &key MERGE-NUMBERS

Transform STRING to camelCase.
Dot-separated numbers like 1.2.3 will be replaced by underscores 1_2_3 unless MERGE-NUMBERS is non-nil.

Package

cl-change-case

Source

cl-change-case.lisp (file)

Function: constant-case STRING

Transform STRING to CONSTANT_CASE.

Package

cl-change-case

Source

cl-change-case.lisp (file)

Function: dot-case STRING

Transform STRING to dot.case

Package

cl-change-case

Source

cl-change-case.lisp (file)

Function: header-case STRING

Transform STRING to Header-Case

Package

cl-change-case

Source

cl-change-case.lisp (file)

Function: lower-case STRING

Downcase each character in STRING.

Package

cl-change-case

Source

cl-change-case.lisp (file)

Function: lower-case-first STRING

Downcase the first character in STRING.

Package

cl-change-case

Source

cl-change-case.lisp (file)

Function: no-case OBJECT &key REPLACEMENT

Transform STRING to lower case space delimited. Use REPLACEMENT as delimiter.

Package

cl-change-case

Source

cl-change-case.lisp (file)

Function: param-case STRING

Transform STRING to param-case

Package

cl-change-case

Source

cl-change-case.lisp (file)

Function: pascal-case STRING

Transform STRING to Pascal Case

Package

cl-change-case

Source

cl-change-case.lisp (file)

Function: path-case STRING

Transform STRING to path/case

Package

cl-change-case

Source

cl-change-case.lisp (file)

Function: sentence-case STRING

Transform STRING to Sentence case

Package

cl-change-case

Source

cl-change-case.lisp (file)

Function: snake-case STRING

Transform STRING to snake_case

Package

cl-change-case

Source

cl-change-case.lisp (file)

Function: string-lower-case-p STRING

Tests if each character in STRING has lower case.

Package

cl-change-case

Source

cl-change-case.lisp (file)

Function: string-upper-case-p STRING

Test if each character in STRING has upper case.

Package

cl-change-case

Source

cl-change-case.lisp (file)

Function: swap-case STRING

Reverse case for each character in STRING.

Package

cl-change-case

Source

cl-change-case.lisp (file)

Function: title-case STRING

Transform STRING to Title Case

Package

cl-change-case

Source

cl-change-case.lisp (file)

Function: upper-case STRING

Upcase each character in STRING.

Package

cl-change-case

Source

cl-change-case.lisp (file)

Function: upper-case-first STRING

Upcase the first character of STRING.

Package

cl-change-case

Source

cl-change-case.lisp (file)


Previous: , Up: Definitions   [Contents][Index]

6.2 Internal definitions


Previous: , Up: Internal definitions   [Contents][Index]

6.2.1 Constants

Constant: +empty-string+
Package

cl-change-case

Source

cl-change-case.lisp (file)


Previous: , Up: Top   [Contents][Index]

Appendix A Indexes


Next: , Previous: , Up: Indexes   [Contents][Index]

A.1 Concepts

Jump to:   C   F   L   M  
Index Entry  Section

C
cl-change-case.asd: The cl-change-case<dot>asd file
cl-change-case/src: The cl-change-case/src module
cl-change-case/src/cl-change-case.lisp: The cl-change-case/src/cl-change-case<dot>lisp file

F
File, Lisp, cl-change-case.asd: The cl-change-case<dot>asd file
File, Lisp, cl-change-case/src/cl-change-case.lisp: The cl-change-case/src/cl-change-case<dot>lisp file

L
Lisp File, cl-change-case.asd: The cl-change-case<dot>asd file
Lisp File, cl-change-case/src/cl-change-case.lisp: The cl-change-case/src/cl-change-case<dot>lisp file

M
Module, cl-change-case/src: The cl-change-case/src module

Jump to:   C   F   L   M  

Next: , Previous: , Up: Indexes   [Contents][Index]

A.2 Functions

Jump to:   C   D   F   H   L   N   P   S   T   U  
Index Entry  Section

C
camel-case: Exported functions
constant-case: Exported functions

D
dot-case: Exported functions

F
Function, camel-case: Exported functions
Function, constant-case: Exported functions
Function, dot-case: Exported functions
Function, header-case: Exported functions
Function, lower-case: Exported functions
Function, lower-case-first: Exported functions
Function, no-case: Exported functions
Function, param-case: Exported functions
Function, pascal-case: Exported functions
Function, path-case: Exported functions
Function, sentence-case: Exported functions
Function, snake-case: Exported functions
Function, string-lower-case-p: Exported functions
Function, string-upper-case-p: Exported functions
Function, swap-case: Exported functions
Function, title-case: Exported functions
Function, upper-case: Exported functions
Function, upper-case-first: Exported functions

H
header-case: Exported functions

L
lower-case: Exported functions
lower-case-first: Exported functions

N
no-case: Exported functions

P
param-case: Exported functions
pascal-case: Exported functions
path-case: Exported functions

S
sentence-case: Exported functions
snake-case: Exported functions
string-lower-case-p: Exported functions
string-upper-case-p: Exported functions
swap-case: Exported functions

T
title-case: Exported functions

U
upper-case: Exported functions
upper-case-first: Exported functions

Jump to:   C   D   F   H   L   N   P   S   T   U  

Next: , Previous: , Up: Indexes   [Contents][Index]

A.3 Variables

Jump to:   +  
C  
Index Entry  Section

+
+empty-string+: Internal constants

C
Constant, +empty-string+: Internal constants

Jump to:   +  
C  

Previous: , Up: Indexes   [Contents][Index]

A.4 Data types

Jump to:   C   P   S  
Index Entry  Section

C
cl-change-case: The cl-change-case system
cl-change-case: The cl-change-case package

P
Package, cl-change-case: The cl-change-case package

S
System, cl-change-case: The cl-change-case system

Jump to:   C   P   S