txt: ## uni.md
  class Uni
  
  A string of Unicode codepoints
  
  ```raku
  class Uni does Positional[uint32] does Stringy { }
  ```
  
  Unlike [`Str`](/type/Str), which is made of Grapheme clusters, Uni is string strictly made of Unicode codepoints. That is, base characters and combining characters are separate elements of a `Uni` instance.
  
  `Uni` presents itself with a list-like interface of integer Codepoints.
  
  Typical usage of `Uni` is through one of its subclasses, [`NFC`](/type/NFC), [`NFD`](/type/NFD), [`NFKD`](/type/NFKD) and [`NFKC`](/type/NFKC), which represent strings in one of the [Unicode Normalization Forms](https://www.unicode.org/reports/tr15/) of the same name.
  
  # [Methods](#class_Uni "go to top of document")[§](#Methods "direct link")
  
  ## [method new](#class_Uni "go to top of document")[§](#method_new "direct link")
  
  ```raku
  method new(*@codes --> Uni:D)
  ```
  
  Creates a new `Uni` instance from the given codepoint numbers.
  
  ## [method list](#class_Uni "go to top of document")[§](#method_list "direct link")
  
  ```raku
  method list(Uni:D:)
  ```
  
  Returns a [`Seq`](/type/Seq) of integer codepoints.
  
  ## [method NFC](#class_Uni "go to top of document")[§](#method_NFC "direct link")
  
  ```raku
  method NFC(Uni:D: --> NFC:D)
  ```
  
  Returns an [`NFC`](/type/NFC) (Normal Form Composed)-converted version of the invocant.
  
  ## [method NFD](#class_Uni "go to top of document")[§](#method_NFD "direct link")
  
  ```raku
  method NFD(Uni:D: --> NFD:D)
  ```
  
  Returns an [`NFD`](/type/NFD) (Normal Form Decomposed)-converted version of the invocant.
  
  ## [method NFKC](#class_Uni "go to top of document")[§](#method_NFKC "direct link")
  
  ```raku
  method NFKC(Uni:D: --> NFKC:D)
  ```
  
  Returns an [`NFKC`](/type/NFKC) (Normal Form Compatibility Composed)-converted version of the invocant.
  
  ## [method NFKD](#class_Uni "go to top of document")[§](#method_NFKD "direct link")
  
  ```raku
  method NFKD(Uni:D: --> NFKD:D)
  ```
  
  Returns an [`NFKD`](/type/NFKD) (Normal Form Compatibility Decomposed)-converted version of the invocant.
  
  ## [method codes](#class_Uni "go to top of document")[§](#method_codes "direct link")
  
  ```raku
  method codes(Uni:D: --> Int:D)
  ```
  
  Returns the number of codepoints in the invocant.
  
  ## [method elems](#class_Uni "go to top of document")[§](#method_elems "direct link")
  
  ```raku
  method elems(Uni:D: --> Int:D)
  ```
  
  Returns the number of codepoints in the invocant.
  
  # [Typegraph](# "go to top of document")[§](#typegraphrelations "direct link")
  
  Type relations for `Uni`
  
  
  
  raku-type-graph
  
  
  
  Uni
  Uni
  
  
  Any
  Any
  
  
  Uni->Any
  
  
  
  Positional
  Positional
  
  
  Uni->Positional
  
  
  
  Stringy
  Stringy
  
  
  Uni->Stringy
  
  
  
  Mu
  Mu
  
  
  Any->Mu
  
  
  
  NFKC
  NFKC
  
  
  NFKC->Uni
  
  
  
  NFD
  NFD
  
  
  NFD->Uni
  
  
  
  NFC
  NFC
  
  
  NFC->Uni
  
  
  
  NFKD
  NFKD
  
  
  NFKD->Uni
  
  [Expand chart above](/assets/typegraphs/Uni.svg)
  