public static function _randString($length, $lettersNumbersOnly = false) {
        $str = '';
        for ($i = 0; $i < $length; $i++) {
            if ($lettersNumbersOnly) {
                $str .= self::$lettersNums[self::_getRand(0, strlen(self::$lettersNums) - 1)];
            } else {
                $str .= self::_randCharacter();
            }
        }
        return $str;
    }