Module: UnicodeScriptDetector
- Defined in:
- lib/unicode_script_detector.rb,
lib/unicode_script_detector/scripts.rb,
lib/unicode_script_detector/version.rb,
lib/unicode_script_detector/detector.rb,
lib/unicode_script_detector/character.rb,
lib/unicode_script_detector/confusables.rb,
lib/unicode_script_detector/script_group.rb,
lib/unicode_script_detector/spoof_detector.rb
Defined Under Namespace
Modules: Confusables
Classes: Character, Detector, ScriptGroup, Scripts, SpoofDetector
Constant Summary
collapse
- VERSION =
"0.0.10"
Class Method Summary
collapse
Class Method Details
.contains?(string, scripts) ⇒ Boolean
16
17
18
|
# File 'lib/unicode_script_detector.rb', line 16
def contains?(string, scripts)
UnicodeScriptDetector::Detector.new(string).contains?(scripts)
end
|
.contains_only?(string, scripts) ⇒ Boolean
20
21
22
|
# File 'lib/unicode_script_detector.rb', line 20
def contains_only?(string, scripts)
UnicodeScriptDetector::Detector.new(string).contains_only?(scripts)
end
|
.detect_characters(string) ⇒ Object
8
9
10
|
# File 'lib/unicode_script_detector.rb', line 8
def detect_characters(string)
UnicodeScriptDetector::Detector.new(string).characters
end
|
.script_groups(string) ⇒ Object
12
13
14
|
# File 'lib/unicode_script_detector.rb', line 12
def script_groups(string)
UnicodeScriptDetector::Detector.new(string).script_groups
end
|
.spoof_analysis(string) ⇒ Object
24
25
26
|
# File 'lib/unicode_script_detector.rb', line 24
def spoof_analysis(string)
UnicodeScriptDetector::SpoofDetector.new(string).detections
end
|
.spoofed?(string) ⇒ Boolean
28
29
30
|
# File 'lib/unicode_script_detector.rb', line 28
def spoofed?(string)
UnicodeScriptDetector::SpoofDetector.new(string).spoofed?
end
|