classes-Com-Tecnick-Unicode-Bidi

It appears that you are using AdBlocking software. The cost of running this website is covered by advertisements. If you like it please feel free to a small amount of money to secure the future of this website.

Bidi

in package

Com\Tecnick\Unicode\Bidi

Tags
since
2015-07-13
category

Library

author

Nicola Asuni info@tecnick.com

copyright

2011-2024 Nicola Asuni - Tecnick.com LTD

license

http://www.gnu.org/copyleft/lesser.html GNU-LGPL v3 (see LICENSE.TXT)

link
https://github.com/tecnickcom/tc-lib-unicode

Table of Contents

Methods

__construct()  : mixed
Reverse the RLT substrings using the Bidirectional Algorithm http://unicode.org/reports/tr9/
getCharKeys()  : array<int, true>
Returns an array with processed chars as keys
getChrArray()  : array<string|int, string>
Returns the processed array of UTF-8 chars
getNumChars()  : int
Returns the number of characters in the processed string
getOrdArray()  : array<string|int, int>
Returns the processed array of UTF-8 codepoints
getString()  : string
Returns the processed string

Methods

__construct()

Reverse the RLT substrings using the Bidirectional Algorithm http://unicode.org/reports/tr9/

public __construct([string|null $str = null ][, array<string|int, string>|null $chrarr = null ][, array<string|int, int>|null $ordarr = null ][, string $forcedir = '' ][, bool $shaping = true ]) : mixed
Parameters
$str : string|null = null

String to convert (if null it will be generated from $chrarr or $ordarr)

$chrarr : array<string|int, string>|null = null

Array of UTF-8 chars (if empty it will be generated from $str or $ordarr)

$ordarr : array<string|int, int>|null = null

Array of UTF-8 codepoints (if empty it will be generated from $str or $chrarr)

$forcedir : string = ''

If 'R' forces RTL, if 'L' forces LTR

$shaping : bool = true

If true enable the shaping algorithm

getCharKeys()

Returns an array with processed chars as keys

public getCharKeys() : array<int, true>
Return values
array<int, true>

getChrArray()

Returns the processed array of UTF-8 chars

public getChrArray() : array<string|int, string>
Return values
array<string|int, string>

getNumChars()

Returns the number of characters in the processed string

public getNumChars() : int
Return values
int

getOrdArray()

Returns the processed array of UTF-8 codepoints

public getOrdArray() : array<string|int, int>
Return values
array<string|int, int>

getString()

Returns the processed string

public getString() : string
Return values
string
On this page
 

© 2004-2024 – Nicola Asuni - Tecnick.com - All rights reserved.
about - disclaimer - privacy