UnicodeTranscoderInterface.php 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. <?php
  2. /**
  3. * UCTC - The Unicode Transcoder
  4. *
  5. * Converts between various flavours of Unicode representations like UCS-4 or UTF-8
  6. * Supported schemes:
  7. * - UCS-4 Little Endian / Big Endian / Array (partially)
  8. * - UTF-16 Little Endian / Big Endian (not yet)
  9. * - UTF-8
  10. * - UTF-7
  11. * - UTF-7 IMAP (modified UTF-7)
  12. *
  13. * @package IdnaConvert
  14. * @author Matthias Sommerfeld <mso@phlyLabs.de>
  15. * @copyright 2003-2016 phlyLabs Berlin, http://phlylabs.de
  16. * @version 0.1.0 2016-01-08
  17. */
  18. namespace Mso\IdnaConvert;
  19. interface UnicodeTranscoderInterface
  20. {
  21. public static function convert($data, $from, $to, $safe_mode = false, $safe_char = 0xFFFC);
  22. public static function utf8_ucs4array($input);
  23. public static function ucs4array_utf8($input);
  24. public static function utf7imap_ucs4array($input);
  25. public static function utf7_ucs4array($input, $sc = '+');
  26. public static function ucs4array_utf7imap($input);
  27. public static function ucs4array_utf7($input, $sc = '+');
  28. public static function ucs4array_ucs4($input);
  29. public static function ucs4_ucs4array($input);
  30. }