CharacterArray.st
changeset 4974 cde2ee5adeb0
parent 4890 fa9abaa225ef
child 4981 2ee8cd2c4c8e
equal deleted inserted replaced
4973:2bbd09250179 4974:cde2ee5adeb0
  2243     "Modified: / 18.6.1998 / 16:04:46 / cg"
  2243     "Modified: / 18.6.1998 / 16:04:46 / cg"
  2244 ! !
  2244 ! !
  2245 
  2245 
  2246 !CharacterArray methodsFor:'Compatibility - Squeak'!
  2246 !CharacterArray methodsFor:'Compatibility - Squeak'!
  2247 
  2247 
       
  2248 includesSubString:aString
       
  2249     "return true, if a substring is contained in the receiver.
       
  2250      The compare is case sensitive."
       
  2251 
       
  2252     ^ self includesString:aString
       
  2253 
       
  2254     "
       
  2255      'hello world' includesSubString:'Hel'  
       
  2256      'hello world' includesSubString:'hel'  
       
  2257      'hello world' includesSubString:'llo'  
       
  2258     "
       
  2259 
       
  2260 
       
  2261 
       
  2262 !
       
  2263 
  2248 includesSubstring:aString caseSensitive:caseSensitive
  2264 includesSubstring:aString caseSensitive:caseSensitive
  2249     "return true, if a substring is contained in the receiver.
  2265     "return true, if a substring is contained in the receiver.
  2250      The argument, caseSensitive controls if case is ignored in the compare."
  2266      The argument, caseSensitive controls if case is ignored in the compare."
  2251 
  2267 
  2252     "/ for now,  a q&d hack ...
  2268     "/ for now,  a q&d hack ...
  3249 !
  3265 !
  3250 
  3266 
  3251 asText
  3267 asText
  3252     "return a Text-object (collection of lines) from myself."
  3268     "return a Text-object (collection of lines) from myself."
  3253 
  3269 
       
  3270     Text isNil ifTrue:[^ self].
  3254     ^ Text fromString:self
  3271     ^ Text fromString:self
  3255 
  3272 
  3256     "Created: 12.5.1996 / 10:41:14 / cg"
  3273     "Created: 12.5.1996 / 10:41:14 / cg"
  3257 !
  3274 !
  3258 
  3275 
  5454 ! !
  5471 ! !
  5455 
  5472 
  5456 !CharacterArray class methodsFor:'documentation'!
  5473 !CharacterArray class methodsFor:'documentation'!
  5457 
  5474 
  5458 version
  5475 version
  5459     ^ '$Header: /cvs/stx/stx/libbasic/CharacterArray.st,v 1.169 1999-10-09 15:31:28 cg Exp $'
  5476     ^ '$Header: /cvs/stx/stx/libbasic/CharacterArray.st,v 1.170 1999-11-09 09:31:31 cg Exp $'
  5460 ! !
  5477 ! !
  5461 CharacterArray initialize!
  5478 CharacterArray initialize!