Skip to content

Latest commit

 

History

History
2146 lines (781 loc) · 33.7 KB

AbstractUnicodeString.md

File metadata and controls

2146 lines (781 loc) · 33.7 KB
*** # AbstractUnicodeString Represents a string of abstract Unicode characters. Unicode defines 3 types of "characters" (bytes, code points and grapheme clusters). This class is the abstract type to use as a type-hint when the logic you want to implement is Unicode-aware but doesn't care about code points vs grapheme clusters. * Full name: `\Symfony\Component\String\AbstractUnicodeString` * Parent class: [`\Symfony\Component\String\AbstractString`](./AbstractString.md) * This class is an **Abstract class** ## Constants | Constant | Visibility | Type | Value | |:---------|:-----------|:-----|:------| |`NFC`|public| |\Normalizer::NFC| |`NFD`|public| |\Normalizer::NFD| |`NFKC`|public| |\Normalizer::NFKC| |`NFKD`|public| |\Normalizer::NFKD| |`ASCII`|private| |" eiasntrolud][cmp'\ng|hv.fb,:=-q10C2*yx)(L9AS/P\"EjMIk3>5T<D4}B{8FwR67UGN;JzV#HOW_&!K?XQ%Y\\\tZ+~^\$@`�\x00\x01\x02\x03\x04\x05\x06\x07\x08\v\f\r\x0e\x0f\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"| |`FOLD_FROM`|private| |['İ', 'µ', 'ſ', "ͅ", 'ς', 'ϐ', 'ϑ', 'ϕ', 'ϖ', 'ϰ', 'ϱ', 'ϵ', 'ẛ', "ι", 'ß', 'İ', 'ʼn', 'ǰ', 'ΐ', 'ΰ', 'և', 'ẖ', 'ẗ', 'ẘ', 'ẙ', 'ẚ', 'ẞ', 'ὐ', 'ὒ', 'ὔ', 'ὖ', 'ᾀ', 'ᾁ', 'ᾂ', 'ᾃ', 'ᾄ', 'ᾅ', 'ᾆ', 'ᾇ', 'ᾈ', 'ᾉ', 'ᾊ', 'ᾋ', 'ᾌ', 'ᾍ', 'ᾎ', 'ᾏ', 'ᾐ', 'ᾑ', 'ᾒ', 'ᾓ', 'ᾔ', 'ᾕ', 'ᾖ', 'ᾗ', 'ᾘ', 'ᾙ', 'ᾚ', 'ᾛ', 'ᾜ', 'ᾝ', 'ᾞ', 'ᾟ', 'ᾠ', 'ᾡ', 'ᾢ', 'ᾣ', 'ᾤ', 'ᾥ', 'ᾦ', 'ᾧ', 'ᾨ', 'ᾩ', 'ᾪ', 'ᾫ', 'ᾬ', 'ᾭ', 'ᾮ', 'ᾯ', 'ᾲ', 'ᾳ', 'ᾴ', 'ᾶ', 'ᾷ', 'ᾼ', 'ῂ', 'ῃ', 'ῄ', 'ῆ', 'ῇ', 'ῌ', 'ῒ', 'ΐ', 'ῖ', 'ῗ', 'ῢ', 'ΰ', 'ῤ', 'ῦ', 'ῧ', 'ῲ', 'ῳ', 'ῴ', 'ῶ', 'ῷ', 'ῼ', 'ff', 'fi', 'fl', 'ffi', 'ffl', 'ſt', 'st', 'ﬓ', 'ﬔ', 'ﬕ', 'ﬖ', 'ﬗ']| |`FOLD_TO`|private| |['i̇', 'μ', 's', 'ι', 'σ', 'β', 'θ', 'φ', 'π', 'κ', 'ρ', 'ε', 'ṡ', 'ι', 'ss', 'i̇', 'ʼn', 'ǰ', 'ΐ', 'ΰ', 'եւ', 'ẖ', 'ẗ', 'ẘ', 'ẙ', 'aʾ', 'ss', 'ὐ', 'ὒ', 'ὔ', 'ὖ', 'ἀι', 'ἁι', 'ἂι', 'ἃι', 'ἄι', 'ἅι', 'ἆι', 'ἇι', 'ἀι', 'ἁι', 'ἂι', 'ἃι', 'ἄι', 'ἅι', 'ἆι', 'ἇι', 'ἠι', 'ἡι', 'ἢι', 'ἣι', 'ἤι', 'ἥι', 'ἦι', 'ἧι', 'ἠι', 'ἡι', 'ἢι', 'ἣι', 'ἤι', 'ἥι', 'ἦι', 'ἧι', 'ὠι', 'ὡι', 'ὢι', 'ὣι', 'ὤι', 'ὥι', 'ὦι', 'ὧι', 'ὠι', 'ὡι', 'ὢι', 'ὣι', 'ὤι', 'ὥι', 'ὦι', 'ὧι', 'ὰι', 'αι', 'άι', 'ᾶ', 'ᾶι', 'αι', 'ὴι', 'ηι', 'ήι', 'ῆ', 'ῆι', 'ηι', 'ῒ', 'ΐ', 'ῖ', 'ῗ', 'ῢ', 'ΰ', 'ῤ', 'ῦ', 'ῧ', 'ὼι', 'ωι', 'ώι', 'ῶ', 'ῶι', 'ωι', 'ff', 'fi', 'fl', 'ffi', 'ffl', 'st', 'st', 'մն', 'մե', 'մի', 'վն', 'մխ']| |`UPPER_FROM`|private| |['ß', 'ff', 'fi', 'fl', 'ffi', 'ffl', 'ſt', 'st', 'և', 'ﬓ', 'ﬔ', 'ﬕ', 'ﬖ', 'ﬗ', 'ʼn', 'ΐ', 'ΰ', 'ǰ', 'ẖ', 'ẗ', 'ẘ', 'ẙ', 'ẚ', 'ὐ', 'ὒ', 'ὔ', 'ὖ', 'ᾶ', 'ῆ', 'ῒ', 'ΐ', 'ῖ', 'ῗ', 'ῢ', 'ΰ', 'ῤ', 'ῦ', 'ῧ', 'ῶ']| |`UPPER_TO`|private| |['SS', 'FF', 'FI', 'FL', 'FFI', 'FFL', 'ST', 'ST', 'ԵՒ', 'ՄՆ', 'ՄԵ', 'ՄԻ', 'ՎՆ', 'ՄԽ', 'ʼN', 'Ϊ́', 'Ϋ́', 'J̌', 'H̱', 'T̈', 'W̊', 'Y̊', 'Aʾ', 'Υ̓', 'Υ̓̀', 'Υ̓́', 'Υ̓͂', 'Α͂', 'Η͂', 'Ϊ̀', 'Ϊ́', 'Ι͂', 'Ϊ͂', 'Ϋ̀', 'Ϋ́', 'Ρ̓', 'Υ͂', 'Ϋ͂', 'Ω͂']| |`TRANSLIT_FROM`|private| |['Æ', 'Ð', 'Ø', 'Þ', 'ß', 'æ', 'ð', 'ø', 'þ', 'Đ', 'đ', 'Ħ', 'ħ', 'ı', 'ĸ', 'Ŀ', 'ŀ', 'Ł', 'ł', 'ʼn', 'Ŋ', 'ŋ', 'Œ', 'œ', 'Ŧ', 'ŧ', 'ƀ', 'Ɓ', 'Ƃ', 'ƃ', 'Ƈ', 'ƈ', 'Ɖ', 'Ɗ', 'Ƌ', 'ƌ', 'Ɛ', 'Ƒ', 'ƒ', 'Ɠ', 'ƕ', 'Ɩ', 'Ɨ', 'Ƙ', 'ƙ', 'ƚ', 'Ɲ', 'ƞ', 'Ƣ', 'ƣ', 'Ƥ', 'ƥ', 'ƫ', 'Ƭ', 'ƭ', 'Ʈ', 'Ʋ', 'Ƴ', 'ƴ', 'Ƶ', 'ƶ', 'DŽ', 'Dž', 'dž', 'Ǥ', 'ǥ', 'ȡ', 'Ȥ', 'ȥ', 'ȴ', 'ȵ', 'ȶ', 'ȷ', 'ȸ', 'ȹ', 'Ⱥ', 'Ȼ', 'ȼ', 'Ƚ', 'Ⱦ', 'ȿ', 'ɀ', 'Ƀ', 'Ʉ', 'Ɇ', 'ɇ', 'Ɉ', 'ɉ', 'Ɍ', 'ɍ', 'Ɏ', 'ɏ', 'ɓ', 'ɕ', 'ɖ', 'ɗ', 'ɛ', 'ɟ', 'ɠ', 'ɡ', 'ɢ', 'ɦ', 'ɧ', 'ɨ', 'ɪ', 'ɫ', 'ɬ', 'ɭ', 'ɱ', 'ɲ', 'ɳ', 'ɴ', 'ɶ', 'ɼ', 'ɽ', 'ɾ', 'ʀ', 'ʂ', 'ʈ', 'ʉ', 'ʋ', 'ʏ', 'ʐ', 'ʑ', 'ʙ', 'ʛ', 'ʜ', 'ʝ', 'ʟ', 'ʠ', 'ʣ', 'ʥ', 'ʦ', 'ʪ', 'ʫ', 'ᴀ', 'ᴁ', 'ᴃ', 'ᴄ', 'ᴅ', 'ᴆ', 'ᴇ', 'ᴊ', 'ᴋ', 'ᴌ', 'ᴍ', 'ᴏ', 'ᴘ', 'ᴛ', 'ᴜ', 'ᴠ', 'ᴡ', 'ᴢ', 'ᵫ', 'ᵬ', 'ᵭ', 'ᵮ', 'ᵯ', 'ᵰ', 'ᵱ', 'ᵲ', 'ᵳ', 'ᵴ', 'ᵵ', 'ᵶ', 'ᵺ', 'ᵻ', 'ᵽ', 'ᵾ', 'ᶀ', 'ᶁ', 'ᶂ', 'ᶃ', 'ᶄ', 'ᶅ', 'ᶆ', 'ᶇ', 'ᶈ', 'ᶉ', 'ᶊ', 'ᶌ', 'ᶍ', 'ᶎ', 'ᶏ', 'ᶑ', 'ᶒ', 'ᶓ', 'ᶖ', 'ᶙ', 'ẚ', 'ẜ', 'ẝ', 'ẞ', 'Ỻ', 'ỻ', 'Ỽ', 'ỽ', 'Ỿ', 'ỿ', '©', '®', '₠', '₢', '₣', '₤', '₧', '₺', '₹', 'ℌ', '℞', '㎧', '㎮', '㏆', '㏗', '㏞', '㏟', '¼', '½', '¾', '⅓', '⅔', '⅕', '⅖', '⅗', '⅘', '⅙', '⅚', '⅛', '⅜', '⅝', '⅞', '⅟', '〇', '‘', '’', '‚', '‛', '“', '”', '„', '‟', '′', '″', '〝', '〞', '«', '»', '‹', '›', '‐', '‑', '‒', '–', '—', '―', '︱', '︲', '﹘', '‖', '⁄', '⁅', '⁆', '⁎', '、', '。', '〈', '〉', '《', '》', '〔', '〕', '〘', '〙', '〚', '〛', '︑', '︒', '︹', '︺', '︽', '︾', '︿', '﹀', '﹑', '﹝', '﹞', '⦅', '⦆', '。', '、', '×', '÷', '−', '∕', '∖', '∣', '∥', '≪', '≫', '⦅', '⦆']| |`TRANSLIT_TO`|private| |['AE', 'D', 'O', 'TH', 'ss', 'ae', 'd', 'o', 'th', 'D', 'd', 'H', 'h', 'i', 'q', 'L', 'l', 'L', 'l', '\'n', 'N', 'n', 'OE', 'oe', 'T', 't', 'b', 'B', 'B', 'b', 'C', 'c', 'D', 'D', 'D', 'd', 'E', 'F', 'f', 'G', 'hv', 'I', 'I', 'K', 'k', 'l', 'N', 'n', 'OI', 'oi', 'P', 'p', 't', 'T', 't', 'T', 'V', 'Y', 'y', 'Z', 'z', 'DZ', 'Dz', 'dz', 'G', 'g', 'd', 'Z', 'z', 'l', 'n', 't', 'j', 'db', 'qp', 'A', 'C', 'c', 'L', 'T', 's', 'z', 'B', 'U', 'E', 'e', 'J', 'j', 'R', 'r', 'Y', 'y', 'b', 'c', 'd', 'd', 'e', 'j', 'g', 'g', 'G', 'h', 'h', 'i', 'I', 'l', 'l', 'l', 'm', 'n', 'n', 'N', 'OE', 'r', 'r', 'r', 'R', 's', 't', 'u', 'v', 'Y', 'z', 'z', 'B', 'G', 'H', 'j', 'L', 'q', 'dz', 'dz', 'ts', 'ls', 'lz', 'A', 'AE', 'B', 'C', 'D', 'D', 'E', 'J', 'K', 'L', 'M', 'O', 'P', 'T', 'U', 'V', 'W', 'Z', 'ue', 'b', 'd', 'f', 'm', 'n', 'p', 'r', 'r', 's', 't', 'z', 'th', 'I', 'p', 'U', 'b', 'd', 'f', 'g', 'k', 'l', 'm', 'n', 'p', 'r', 's', 'v', 'x', 'z', 'a', 'd', 'e', 'e', 'i', 'u', 'a', 's', 's', 'SS', 'LL', 'll', 'V', 'v', 'Y', 'y', '(C)', '(R)', 'CE', 'Cr', 'Fr.', 'L.', 'Pts', 'TL', 'Rs', 'x', 'Rx', 'm/s', 'rad/s', 'C/kg', 'pH', 'V/m', 'A/m', ' 1/4', ' 1/2', ' 3/4', ' 1/3', ' 2/3', ' 1/5', ' 2/5', ' 3/5', ' 4/5', ' 1/6', ' 5/6', ' 1/8', ' 3/8', ' 5/8', ' 7/8', ' 1/', '0', '\'', '\'', ',', '\'', '"', '"', ',,', '"', '\'', '"', '"', '"', '<<', '>>', '<', '>', '-', '-', '-', '-', '-', '-', '-', '-', '-', '||', '/', '[', ']', '*', ',', '.', '<', '>', '<<', '>>', '[', ']', '[', ']', '[', ']', ',', '.', '[', ']', '<<', '>>', '<', '>', ',', '[', ']', '((', '))', '.', ',', '*', '/', '-', '/', '\\', '|', '||', '<<', '>>', '((', '))']| ## Properties ### transliterators ```php private static $transliterators ``` * This property is **static**. *** ### tableZero ```php private static $tableZero ``` * This property is **static**. *** ### tableWide ```php private static $tableWide ``` * This property is **static**. *** ## Methods ### fromCodePoints ```php public static fromCodePoints(int $codes): static ``` * This method is **static**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$codes` | **int** | | *** ### ascii Generic UTF-8 to ASCII transliteration. ```php public ascii(string[]|\Transliterator[]|\Closure[] $rules = []): self ``` Install the intl extension for best results. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$rules` | **string[]|\Transliterator[]|\Closure[]** | See "*-Latin" rules from Transliterator::listIDs() | *** ### camel ```php public camel(): static ``` *** ### codePointsAt ```php public codePointsAt(int $offset): int[] ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$offset` | **int** | | *** ### folded ```php public folded(bool $compat = true): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$compat` | **bool** | | *** ### join ```php public join(array $strings, string $lastGlue = null): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$strings` | **array** | | | `$lastGlue` | **string** | | *** ### lower ```php public lower(): static ``` *** ### match Matches the string using a regular expression. ```php public match(string $regexp, int $flags, int $offset): array ``` Pass PREG_PATTERN_ORDER or PREG_SET_ORDER as $flags to get all occurrences matching the regular expression. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$regexp` | **string** | | | `$flags` | **int** | | | `$offset` | **int** | | **Return Value:** All matches in a multi-dimensional array ordered according to flags *** ### normalize ```php public normalize(int $form = self::NFC): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$form` | **int** | | *** ### padBoth ```php public padBoth(int $length, string $padStr = ' '): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$length` | **int** | | | `$padStr` | **string** | | *** ### padEnd ```php public padEnd(int $length, string $padStr = ' '): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$length` | **int** | | | `$padStr` | **string** | | *** ### padStart ```php public padStart(int $length, string $padStr = ' '): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$length` | **int** | | | `$padStr` | **string** | | *** ### replaceMatches ```php public replaceMatches(string $fromRegexp, string|callable $to): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$fromRegexp` | **string** | | | `$to` | **string|callable** | | *** ### reverse ```php public reverse(): static ``` *** ### snake ```php public snake(): static ``` *** ### title ```php public title(bool $allWords = false): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$allWords` | **bool** | | *** ### trim ```php public trim(string $chars = " �  "): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$chars` | **string** | | *** ### trimEnd ```php public trimEnd(string $chars = " �  "): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$chars` | **string** | | *** ### trimPrefix ```php public trimPrefix(mixed $prefix): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$prefix` | **mixed** | | *** ### trimStart ```php public trimStart(string $chars = " �  "): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$chars` | **string** | | *** ### trimSuffix ```php public trimSuffix(mixed $suffix): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$suffix` | **mixed** | | *** ### upper ```php public upper(): static ``` *** ### width Returns the printable length on a terminal. ```php public width(bool $ignoreAnsiDecoration = true): int ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$ignoreAnsiDecoration` | **bool** | | *** ### pad ```php private pad(int $len, self $pad, int $type): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$len` | **int** | | | `$pad` | **self** | | | `$type` | **int** | | *** ### wcswidth Based on https://github.com/jquast/wcwidth, a Python implementation of https://www.cl.cam.ac.uk/~mgk25/ucs/wcwidth.c. ```php private wcswidth(string $string): int ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$string` | **string** | | *** ## Inherited methods ### __construct ```php public __construct(string $string = ''): mixed ``` * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$string` | **string** | | *** ### unwrap Unwraps instances of AbstractString back to strings. ```php public static unwrap(array $values): string[]|array ``` * This method is **static**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$values` | **array** | | *** ### wrap Wraps (and normalizes) strings in instances of AbstractString. ```php public static wrap(array $values): static[]|array ``` * This method is **static**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$values` | **array** | | *** ### after ```php public after(string|string[] $needle, bool $includeNeedle = false, int $offset): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$needle` | **string|string[]** | | | `$includeNeedle` | **bool** | | | `$offset` | **int** | | *** ### afterLast ```php public afterLast(string|string[] $needle, bool $includeNeedle = false, int $offset): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$needle` | **string|string[]** | | | `$includeNeedle` | **bool** | | | `$offset` | **int** | | *** ### append ```php public append(string $suffix): static ``` * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$suffix` | **string** | | *** ### before ```php public before(string|string[] $needle, bool $includeNeedle = false, int $offset): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$needle` | **string|string[]** | | | `$includeNeedle` | **bool** | | | `$offset` | **int** | | *** ### beforeLast ```php public beforeLast(string|string[] $needle, bool $includeNeedle = false, int $offset): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$needle` | **string|string[]** | | | `$includeNeedle` | **bool** | | | `$offset` | **int** | | *** ### bytesAt ```php public bytesAt(int $offset): int[] ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$offset` | **int** | | *** ### camel ```php public camel(): static ``` * This method is **abstract**. *** ### chunk ```php public chunk(int $length = 1): static[] ``` * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$length` | **int** | | *** ### collapseWhitespace ```php public collapseWhitespace(): static ``` *** ### containsAny ```php public containsAny(string|string[] $needle): bool ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$needle` | **string|string[]** | | *** ### endsWith ```php public endsWith(string|string[] $suffix): bool ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$suffix` | **string|string[]** | | *** ### ensureEnd ```php public ensureEnd(string $suffix): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$suffix` | **string** | | *** ### ensureStart ```php public ensureStart(string $prefix): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$prefix` | **string** | | *** ### equalsTo ```php public equalsTo(string|string[] $string): bool ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$string` | **string|string[]** | | *** ### folded ```php public folded(): static ``` * This method is **abstract**. *** ### ignoreCase ```php public ignoreCase(): static ``` *** ### indexOf ```php public indexOf(string|string[] $needle, int $offset): ?int ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$needle` | **string|string[]** | | | `$offset` | **int** | | *** ### indexOfLast ```php public indexOfLast(string|string[] $needle, int $offset): ?int ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$needle` | **string|string[]** | | | `$offset` | **int** | | *** ### isEmpty ```php public isEmpty(): bool ``` *** ### join ```php public join(array $strings, string $lastGlue = null): static ``` * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$strings` | **array** | | | `$lastGlue` | **string** | | *** ### jsonSerialize ```php public jsonSerialize(): string ``` *** ### length ```php public length(): int ``` * This method is **abstract**. *** ### lower ```php public lower(): static ``` * This method is **abstract**. *** ### match Matches the string using a regular expression. ```php public match(string $regexp, int $flags, int $offset): array ``` Pass PREG_PATTERN_ORDER or PREG_SET_ORDER as $flags to get all occurrences matching the regular expression. * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$regexp` | **string** | | | `$flags` | **int** | | | `$offset` | **int** | | **Return Value:** All matches in a multi-dimensional array ordered according to flags *** ### padBoth ```php public padBoth(int $length, string $padStr = ' '): static ``` * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$length` | **int** | | | `$padStr` | **string** | | *** ### padEnd ```php public padEnd(int $length, string $padStr = ' '): static ``` * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$length` | **int** | | | `$padStr` | **string** | | *** ### padStart ```php public padStart(int $length, string $padStr = ' '): static ``` * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$length` | **int** | | | `$padStr` | **string** | | *** ### prepend ```php public prepend(string $prefix): static ``` * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$prefix` | **string** | | *** ### repeat ```php public repeat(int $multiplier): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$multiplier` | **int** | | *** ### replace ```php public replace(string $from, string $to): static ``` * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$from` | **string** | | | `$to` | **string** | | *** ### replaceMatches ```php public replaceMatches(string $fromRegexp, string|callable $to): static ``` * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$fromRegexp` | **string** | | | `$to` | **string|callable** | | *** ### reverse ```php public reverse(): static ``` * This method is **abstract**. *** ### slice ```php public slice(int $start, int $length = null): static ``` * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$start` | **int** | | | `$length` | **int** | | *** ### snake ```php public snake(): static ``` * This method is **abstract**. *** ### splice ```php public splice(string $replacement, int $start, int $length = null): static ``` * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$replacement` | **string** | | | `$start` | **int** | | | `$length` | **int** | | *** ### split ```php public split(string $delimiter, int $limit = null, int $flags = null): static[] ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$delimiter` | **string** | | | `$limit` | **int** | | | `$flags` | **int** | | *** ### startsWith ```php public startsWith(string|string[] $prefix): bool ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$prefix` | **string|string[]** | | *** ### title ```php public title(bool $allWords = false): static ``` * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$allWords` | **bool** | | *** ### toByteString ```php public toByteString(string $toEncoding = null): \Symfony\Component\String\ByteString ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$toEncoding` | **string** | | *** ### toCodePointString ```php public toCodePointString(): \Symfony\Component\String\CodePointString ``` *** ### toString ```php public toString(): string ``` *** ### toUnicodeString ```php public toUnicodeString(): \Symfony\Component\String\UnicodeString ``` *** ### trim ```php public trim(string $chars = " �  "): static ``` * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$chars` | **string** | | *** ### trimEnd ```php public trimEnd(string $chars = " �  "): static ``` * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$chars` | **string** | | *** ### trimPrefix ```php public trimPrefix(string|string[] $prefix): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$prefix` | **string|string[]** | | *** ### trimStart ```php public trimStart(string $chars = " �  "): static ``` * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$chars` | **string** | | *** ### trimSuffix ```php public trimSuffix(string|string[] $suffix): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$suffix` | **string|string[]** | | *** ### truncate ```php public truncate(int $length, string $ellipsis = '', bool $cut = true): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$length` | **int** | | | `$ellipsis` | **string** | | | `$cut` | **bool** | | *** ### upper ```php public upper(): static ``` * This method is **abstract**. *** ### width Returns the printable length on a terminal. ```php public width(bool $ignoreAnsiDecoration = true): int ``` * This method is **abstract**. **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$ignoreAnsiDecoration` | **bool** | | *** ### wordwrap ```php public wordwrap(int $width = 75, string $break = " ", bool $cut = false): static ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$width` | **int** | | | `$break` | **string** | | | `$cut` | **bool** | | *** ### __sleep ```php public __sleep(): array ``` *** ### __clone ```php public __clone(): mixed ``` *** ### __toString ```php public __toString(): string ``` *** ***