Skip to content

Latest commit

 

History

History
75 lines (51 loc) · 1.42 KB

bmtData.md

File metadata and controls

75 lines (51 loc) · 1.42 KB
Library file Function Sections Content help file
bmtData btmDataFunc 601-607 Data related bmtData.md

Section Six, Data

  • 601 integer user input check
  • 602 alphabet user input check
  • 603 alphanumeric user input check
  • 604 convert string to lowercase
  • 605 convert string to uppercase
  • 606 trim white space from string
  • 607 String Length

Sub-Sections

  1. integer input check

Keyword intcheck, first option the item to be checked if integer

bmtDataFunc intcheck "$age"

Returns 0 for integer , 2 for non integer.

  1. Alphanumeric input check

Keyword alphanumcheck, first option the item to be checked if Alphanumeric

bmtDataFunc alphanumcheck "$address"

Returns 0 for alphanumcheck , 2 for non alphanumcheck.

  1. alphabet input check

Keyword alphacheck) , first option the item to be checked if alphabet

bmtDataFunc alphacheck "$name"

Returns 0 for alphabet , 2 for non alphabet.

  1. convert a string to lowercase
result=$(bmtDataFunc lowercase "TEST")   
echo $result
  1. convert a string to uppercase
result=$(bmtDataFunc upperrcase "test")   
echo $result
  1. trim whitespace from a strin
result2=$(bmtDataFunc trim "       test   "
echo $result2
  1. String Length Returns string length , maximum 249 , 250 is Null string error.
bmtDataFunc strlen "test string 123" #15
echo $?