Skip to content

Runtime Library

Pglapds edited this page Jun 14, 2019 · 1 revision

The ET runtime library is not dependent on another runtime libraries.(such as C,..)



Char

char.upper()

  • Argument(s) : input(char)
  • Return : char
  • Goal : can convert your character into uppercase letter.




char.lower()

  • Argument(s) : input(char)
  • Return : char
  • Goal : can convert your character into lowercase letter.



char.equal()

  • Argument(s) : first-input(char) , second-input(char)
  • Return : bool
  • Goal : Examines the two-character equality.



char.compare()

  • Argument(s) : first-input(char) , second-input(char)
  • Return : int8
  • Goal : Compare the two-character.



char.repeat()

  • Argument(s) : input(char) , time(usize)
  • Return : char
  • Goal : Repeat a character.


String

string.upper()

  • Argument(s) : input(string)
  • Return : string
  • Goal : can convert your string into uppercase letters.


string.lower()

  • Argument(s) : input(string)
  • Return : string
  • Goal : can convert your string into lowercase letters.


string.search()

  • Argument(s) : input(string) , search(char)
  • Return : bool
  • Goal : Search a char in string.



string.searchs()

  • Argument(s) : input(string) , search(string)
  • Return : bool
  • Goal : Search a string in string.



string.replace()

  • Argument(s) : input(string) , search(char) , replace(char)
  • Return : string
  • Goal : Repeat a character to another character in a text.



string.replaces()

  • Argument(s) : input(string) , search(string) , replace(string)
  • Return : string
  • Goal : Repeat a string to another string in a text.



string.equal()

  • Argument(s) : first-input(string) , second-input(string)
  • Return : bool
  • Goal : Examines the two-string equality.



string.compare()

  • Argument(s) : first-input(string) , second-input(string)
  • Return : bool
  • Goal : Compare the two-string.



string.sub()

  • Argument(s) : input(string) , from(int64) , to(int64)
  • Return : string
  • Goal : Getting a limited part of a text string.(begin from $from)



string.limit()

  • Argument(s) : input(string) , length(size)
  • Return : string
  • Goal : Getting a limited part of a text string.(begin from 0)



string.length()

  • Argument(s) : input(string)
  • Return : usize
  • Goal : Calculate the string length



string.lengths()

  • Argument(s) : input(string)
  • Return : usize
  • Goal : Calculate the string length(support UTF-8 characters)



string.chars()

  • Argument(s) : input(string)
  • Return : char[]
  • Goal : Convert string into characters array.


Math



math.sin() , math.cos() , math.tan() , math.cot()