class DeviceDetector::ModelExtractor
Public Instance Methods
call()
click to toggle source
Calls superclass method
DeviceDetector::MetadataExtractor#call
# File lib/device_detector/model_extractor.rb, line 4 def call s = super.to_s.gsub('_',' ').strip s = s.gsub(/ TD$/i, '') return nil if s == 'Build' s.empty? ? nil : s end
Private Instance Methods
metadata_string()
click to toggle source
# File lib/device_detector/model_extractor.rb, line 15 def metadata_string String(regex_meta[:model]) end
regex()
click to toggle source
# File lib/device_detector/model_extractor.rb, line 19 def regex @regex ||= regex_meta[:regex_model] || regex_meta[:regex] end