Class: String
Instance Method Summary collapse
- #afterspace ⇒ Object
- #all_lower? ⇒ Boolean
- #all_upper? ⇒ Boolean
- #allof(small, big) ⇒ Object
- #beforespace ⇒ Object
- #del(*to_delete) ⇒ Object
- #getsjson ⇒ Object
- #in(bigger_thing) ⇒ Object
- #join(str) ⇒ Object
- #lower?(digit) ⇒ Boolean
- #upper?(digit) ⇒ Boolean
Instance Method Details
#afterspace ⇒ Object
123 124 125 |
# File 'lib/crystel.rb', line 123 def afterspace self[self.index(" ")+1..self.length] end |
#all_lower? ⇒ Boolean
108 109 110 |
# File 'lib/crystel.rb', line 108 def all_lower? self == self.downcase end |
#all_upper? ⇒ Boolean
105 106 107 |
# File 'lib/crystel.rb', line 105 def all_upper? self == self.upcase end |
#allof(small, big) ⇒ Object
126 127 128 129 |
# File 'lib/crystel.rb', line 126 def allof(small, big) at = [] end |
#beforespace ⇒ Object
120 121 122 |
# File 'lib/crystel.rb', line 120 def beforespace self[0...self.index(" ")] end |
#del(*to_delete) ⇒ Object
130 131 132 133 134 135 136 |
# File 'lib/crystel.rb', line 130 def del(*to_delete) alslf = self to_delete.each do |item| alslf.gsub!(item, '') end alslf end |
#getsjson ⇒ Object
102 103 104 |
# File 'lib/crystel.rb', line 102 def getsjson JSON.parse(self) end |
#in(bigger_thing) ⇒ Object
117 118 119 |
# File 'lib/crystel.rb', line 117 def in(bigger_thing) bigger_thing.include? self end |
#join(str) ⇒ Object
137 138 139 |
# File 'lib/crystel.rb', line 137 def join(str) self.split('').join(str) end |
#lower?(digit) ⇒ Boolean
114 115 116 |
# File 'lib/crystel.rb', line 114 def lower?(digit) self[digit] == self[digit].upcase end |
#upper?(digit) ⇒ Boolean
111 112 113 |
# File 'lib/crystel.rb', line 111 def upper?(digit) self[digit] == self[digit].downcase end |