Class: Itools::StringHandle
- Inherits:
-
Object
- Object
- Itools::StringHandle
- Defined in:
- lib/itools/find_unuse_img.rb,
lib/itools/string_searcher.rb
Overview
字符串操作类
Class Method Summary collapse
-
.containsStr(originStr, targetStrs) ⇒ Object
originStr中是否包含targetStrs中的内容.
Class Method Details
.containsStr(originStr, targetStrs) ⇒ Object
originStr中是否包含targetStrs中的内容
101 102 103 104 105 106 107 108 |
# File 'lib/itools/find_unuse_img.rb', line 101 def self.containsStr(originStr,targetStrs) targetStrs.each_with_index {|item,idx| if originStr.include?(item) return idx end } return -1 end |