Module: OpenString::CharacterSets

Included in:
String
Defined in:
lib/open_string.rb

Overview

Defines sets of characters such as lowercase.

Class Method Summary collapse

Class Method Details

.allObject



70
71
72
# File 'lib/open_string.rb', line 70

def self.all
  lowercase + uppercase + numbers + specials
end

.lowercaseObject



54
55
56
# File 'lib/open_string.rb', line 54

def self.lowercase
  %w( a b c d e f g h i j k l m n o p q r s t u v w x y z )
end

.numbersObject



62
63
64
# File 'lib/open_string.rb', line 62

def self.numbers
  %w( 0 1 2 3 4 5 6 7 8 9 )
end

.specialsObject



66
67
68
# File 'lib/open_string.rb', line 66

def self.specials
  %w{ ~ ! @ # $ % ^ & * ( ) - _ = + [ ] < > ; : ' " , . ? \ | / }
end

.uppercaseObject



58
59
60
# File 'lib/open_string.rb', line 58

def self.uppercase
  %w( A B C D E F G H I J K L M N O P Q R S T U V W X Y Z )
end