fullname-matcher 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +18 -0
- data/Gemfile +3 -0
- data/README.md +16 -0
- data/fullname-matcher.gemspec +17 -0
- data/lib/fullname/equivalence.rb +1259 -0
- data/lib/fullname/matcher/core.rb +198 -0
- data/lib/fullname/matcher/version.rb +5 -0
- data/lib/fullname/matcher.rb +15 -0
- data/lib/fullname.rb +4 -0
- metadata +65 -0
data/.gitignore
ADDED
data/Gemfile
ADDED
data/README.md
ADDED
@@ -0,0 +1,16 @@
|
|
1
|
+
fullname_matcher
|
2
|
+
================
|
3
|
+
|
4
|
+
Provide fullname, search in database with proper conditions
|
5
|
+
|
6
|
+
Usage
|
7
|
+
================
|
8
|
+
|
9
|
+
require 'fullname/matcher'
|
10
|
+
|
11
|
+
matcher = Fullname::Matcher.create(User, :first => 'firstname', :middle => 'middlename', :last => 'lastname', :suffix => 'suffix') do |m|
|
12
|
+
m.set_condition "data_import_key = '2013.01.01'"
|
13
|
+
m.match_fullname('Xiaohui, Zhang') # match fullname string in block
|
14
|
+
end
|
15
|
+
|
16
|
+
matcher.match_fullname('Zhang', nil, 'Xiaohui', nil) # match parsed fullname out of block
|
@@ -0,0 +1,17 @@
|
|
1
|
+
$:.unshift File.expand_path("../lib", __FILE__)
|
2
|
+
require 'fullname/matcher/version'
|
3
|
+
|
4
|
+
Gem::Specification.new do |s|
|
5
|
+
s.name = 'fullname-matcher'
|
6
|
+
s.version = Fullname::Matcher::VERSION
|
7
|
+
s.platform = Gem::Platform::RUBY
|
8
|
+
s.authors = ["xiaohui"]
|
9
|
+
s.email = ['wesley@zhangxh.net']
|
10
|
+
s.summary = "Match fullname in database"
|
11
|
+
s.description = "Provide fullname, search in database with proper conditions"
|
12
|
+
s.homepage = 'https://github.com/xiaohui-zhangxh/fullname-matcher'
|
13
|
+
|
14
|
+
s.files = `git ls-files`.split("\n")
|
15
|
+
s.require_path = 'lib'
|
16
|
+
s.add_runtime_dependency(%q<fullname-parser>, ["~> 1.0.0"])
|
17
|
+
end
|