00001 /* 00002 * File Name: plugin_search_criteria.h 00003 */ 00004 00005 /* 00006 * This file is part of uds-plugin-common. 00007 * 00008 * uds-plugin-common is free software: you can redistribute it and/or modify 00009 * it under the terms of the GNU General Public License as published by 00010 * the Free Software Foundation, either version 2 of the License, or 00011 * (at your option) any later version. 00012 * 00013 * uds-plugin-common is distributed in the hope that it will be useful, 00014 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00015 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00016 * GNU General Public License for more details. 00017 * 00018 * You should have received a copy of the GNU General Public License 00019 * along with this program. If not, see <http://www.gnu.org/licenses/>. 00020 */ 00021 00022 /** 00023 * Copyright (C) 2008 iRex Technologies B.V. 00024 * All rights reserved. 00025 */ 00026 00027 #ifndef PLUGIN_SEARCH_CRITERIA_H_ 00028 #define PLUGIN_SEARCH_CRITERIA_H_ 00029 00030 #ifdef __cplusplus 00031 extern "C" { 00032 #endif 00033 00034 #include "plugin_type.h" 00035 #include "plugin_unknown.h" 00036 00037 /** 00038 * @brief Univeral Document Shell Plugin Document Search Criteria interface 00039 * Through IPluginSearchCriteria, caller can set search criteria on 00040 * specified document object. 00041 */ 00042 typedef struct 00043 { 00044 /** 00045 * @brief Define the search text. 00046 * @param thiz The IPluginUnknown pointer of search criteria object. 00047 * @param text The string pattern. 00048 * NOTE: This pattern MUST be UTF-8. 00049 */ 00050 PluginStatus (* set_search_text)( IPluginUnknown *thiz, 00051 const UDSString *text ); 00052 00053 /** 00054 * @brief Define whether the searching is case sensitive. 00055 * @param thiz The IPluginUnknown pointer to the IPluginSearchCriteria 00056 * object. 00057 * @param is_sensitive Specify whether the searching is case sensitive 00058 * or not. By default it is case insensitive. 00059 * @return TODO. Add return codes here. 00060 */ 00061 PluginStatus (* set_case_sensitive)( IPluginUnknown *thiz, 00062 const PluginBool is_sensitive ); 00063 00064 /** 00065 * @brief Define whether searching matches the whole word or not. 00066 * @param thiz The IPluginUnknown pointer of the search criteria object. 00067 * @param do_match_word Specify whether match the whole word or not. 00068 * By default it should NOT match the whole word. 00069 * @return TODO. Add return codes here. 00070 */ 00071 PluginStatus (* set_match_whole_word)( IPluginUnknown *thiz, 00072 const PluginBool do_match_word ); 00073 00074 /** 00075 * @brief Define whether search forward or not. 00076 * @param thiz The IPluginUnknown pointer of the search criteria object. 00077 * @param do_search_forward Specify whether support forward searching or 00078 * not. 00079 * @return TODO. Add return codes here. 00080 */ 00081 PluginStatus (* set_forward)( IPluginUnknown *thiz, 00082 const PluginBool do_search_forward ); 00083 00084 } IPluginSearchCriteria; 00085 00086 #ifdef __cplusplus 00087 } 00088 #endif 00089 00090 #endif 00091