| Author |
interface spec.
|
Yan Zhou
Ranch Hand
Joined: Sep 02, 2003
Posts: 136
|
|
My B&S spec. says: // Returns an array of record numbers that match the specified // criteria. Field n in the database file is described by // criteria[n]. A null value in criteria[n] matches any field // value. A non-null value in criteria[n] matches any field // value that begins with criteria[n]. (For example, "Fred" // matches "Fred" or "Freddy".) public int [] find(String [] criteria) I personally think this method should run with case-insensitive, since that would be more useful. However, the spec. does not seem to suggest so. I wonder how you implement your search: case sensitive or insensitive? If case sensitive, how do you make sure that when user searches for "roofing", you also return "Roofing" (otherwise it would be user unfriendly)? Thanks. Yan
|
 |
Inuka Vincit
Ranch Hand
Joined: Aug 10, 2004
Posts: 175
|
|
I am not sure about your spec but mine says EXACT MATCH for searches(which means you need to do some magic before you display the search results). There is a string method int compareToIgnoreCase(String str) if you wish to use it as an optional feature. Remember the MUST requirements if you dont have it you will be docked. [ October 25, 2004: Message edited by: Inuka Vincit ]
|
MCP (C# application dev 70-316) 860<br />SCJP 1.4 100% SCJD (URLyBird) 378<br />MAD 100% nuts
|
 |
 |
|
|
subject: interface spec.
|
|
|