The SWORD Project  1.9.0.svnversion
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
swsearchable.cpp
Go to the documentation of this file.
1 /******************************************************************************
2  *
3  * swsearchable.cpp - used to provide an interface for objects that
4  * can be searched
5  *
6  * $Id: swsearchable.cpp 2980 2013-09-14 21:51:47Z scribe $
7  *
8  * Copyright 2003-2013 CrossWire Bible Society (http://www.crosswire.org)
9  * CrossWire Bible Society
10  * P. O. Box 2528
11  * Tempe, AZ 85280-2528
12  *
13  * This program is free software; you can redistribute it and/or modify it
14  * under the terms of the GNU General Public License as published by the
15  * Free Software Foundation version 2.
16  *
17  * This program is distributed in the hope that it will be useful, but
18  * WITHOUT ANY WARRANTY; without even the implied warranty of
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20  * General Public License for more details.
21  *
22  */
23 
24 #include <swsearchable.h>
25 #include <listkey.h>
26 
27 
29 
30 
31 void SWSearchable::nullPercent(char percent, void *percentUserData) {}
32 
33 
35 }
36 
37 
39 }
40 
41 
42 // special search framework
43 signed char SWSearchable::createSearchFramework(void (*percent)(char, void *), void *percentUserData) {
44  return 0;
45 }
46 
47 
49 }
50 
51 
52 bool SWSearchable::isSearchOptimallySupported(const char *istr, int searchType, int flags, SWKey *scope) {
53  bool retVal = false;
54  search(istr, searchType, flags, scope, &retVal);
55  return retVal;
56 }
57 
58 
60 
#define SWORD_NAMESPACE_START
Definition: defs.h:39
virtual void deleteSearchFramework()
static void nullPercent(char percent, void *userData)
virtual ListKey & search(const char *istr, int searchType=0, int flags=0, SWKey *scope=0, bool *justCheckIfSupported=0, void(*percent)(char, void *)=&nullPercent, void *percentUserData=0)=0
virtual signed char createSearchFramework(void(*percent)(char, void *)=&nullPercent, void *percentUserData=0)
virtual bool isSearchOptimallySupported(const char *istr, int searchType, int flags, SWKey *scope)
virtual ~SWSearchable()
#define SWORD_NAMESPACE_END
Definition: defs.h:40
Definition: swkey.h:77