Browse Source

Updating docs

master
Tom Lingham 10 years ago
parent
commit
c9f28197c0
  1. 20
      README.md

20
README.md

@ -15,7 +15,7 @@ Add `"tom-lingham/searchy" : "dev-master"` to your composer.json file under `req
"tom-lingham/searchy" : "dev-master" "tom-lingham/searchy" : "dev-master"
} }
``` ```
Run `composer update` in your terminal to pull down into your vendors folder.
Run `composer update` in your terminal to pull the package down into your vendors folder.
Add the service provider to the `providers` array in Laravel's app/config/app.php file: Add the service provider to the `providers` array in Laravel's app/config/app.php file:
```php ```php
@ -129,48 +129,36 @@ Matches an exact string and applies a high multiplier to bring any exact matches
#### StartOfStringMatcher #### StartOfStringMatcher
Matches Strings that begin with the search string. Matches Strings that begin with the search string.
For example, a search for 'hel' would match; 'Hello World' or 'helping hand' For example, a search for 'hel' would match; 'Hello World' or 'helping hand'
#### AcronymMatcher #### AcronymMatcher
Matches strings for Acronym 'like' matches but does NOT return Studly Case Matches Matches strings for Acronym 'like' matches but does NOT return Studly Case Matches
For example, a search for 'fb' would match; 'foo bar' or 'Fred Brown' but not 'FreeBeer'. For example, a search for 'fb' would match; 'foo bar' or 'Fred Brown' but not 'FreeBeer'.
#### ConsecutiveCharactersMatcher #### ConsecutiveCharactersMatcher
Matches strings that include all the characters in the search relatively positioned within the string. It also calculates the percentage of characters in the string that are matched and applies the multiplier accordingly. Matches strings that include all the characters in the search relatively positioned within the string. It also calculates the percentage of characters in the string that are matched and applies the multiplier accordingly.
For Example, a search for 'fba' would match; 'Foo Bar' or 'Afraid of bats', but not 'fabulous' For Example, a search for 'fba' would match; 'Foo Bar' or 'Afraid of bats', but not 'fabulous'
#### StartOfWordsMatcher #### StartOfWordsMatcher
Matches the start of each word against each word in a search. Matches the start of each word against each word in a search.
For example, a search for 'jo ta' would match; 'John Taylor' or 'Joshua B. Takeshi' For example, a search for 'jo ta' would match; 'John Taylor' or 'Joshua B. Takeshi'
#### StudlyCaseMatcher #### StudlyCaseMatcher
Matches Studly Case strings using the first letters of the words only Matches Studly Case strings using the first letters of the words only
For example a search for 'hp' would match; 'HtmlServiceProvider' or 'HashParser' but not 'hasProvider' For example a search for 'hp' would match; 'HtmlServiceProvider' or 'HashParser' but not 'hasProvider'
#### InStringMatcher #### InStringMatcher
Matches against any occurrences of a string within a string and is case-insensitive. Matches against any occurrences of a string within a string and is case-insensitive.
For example, a search for 'smi' would match; 'John Smith' or 'Smiley Face' For example, a search for 'smi' would match; 'John Smith' or 'Smiley Face'
#### TimesInStringMatcher #### TimesInStringMatcher
Matches a string based on how many times the search string appears inside the string
it then applies the multiplier for each occurrence.
Matches a string based on how many times the search string appears inside the string it then applies the multiplier for each occurrence.
For example, a search for 'tha' would match; 'I hope that that cat has caught that mouse' (3 x multiplier) or 'Thanks, it was great!' (1 x multiplier) For example, a search for 'tha' would match; 'I hope that that cat has caught that mouse' (3 x multiplier) or 'Thanks, it was great!' (1 x multiplier)
@ -199,5 +187,5 @@ To the future! The intention is to (eventually):
1. Remove Searchy's dependancy on Laravel 1. Remove Searchy's dependancy on Laravel
2. Include more drivers for more advanced searching (Including file system searching, indexing and more) 2. Include more drivers for more advanced searching (Including file system searching, indexing and more)
3. Implement an AJAX friendly interface for searching models and implementing autosuggestion features on the front end
4. Speed up search performance
3. Implement an AJAX friendly interface for searching models and implementing auto-suggestion features on the front end
4. Speed up search performance and improve result relevance
Loading…
Cancel
Save