NCBI C++ ToolKit
Search_func.hpp
Go to the documentation of this file.

Go to the SVN repository for this file.

1 /* $Id: Search_func.hpp 82960 2018-07-18 20:15:13Z kachalos $
2  * ===========================================================================
3  *
4  * PUBLIC DOMAIN NOTICE
5  * National Center for Biotechnology Information
6  *
7  * This software/database is a "United States Government Work" under the
8  * terms of the United States Copyright Act. It was written as part of
9  * the author's official duties as a United States Government employee and
10  * thus cannot be copyrighted. This software/database is freely available
11  * to the public for use. The National Library of Medicine and the U.S.
12  * Government have not placed any restriction on its use or reproduction.
13  *
14  * Although all reasonable efforts have been taken to ensure the accuracy
15  * and reliability of the software and data, the NLM and the U.S.
16  * Government do not and cannot warrant the performance or results that
17  * may be obtained by using this software or data. The NLM and the U.S.
18  * Government disclaim all warranties, express or implied, including
19  * warranties of performance, merchantability or fitness for any particular
20  * purpose.
21  *
22  * Please cite the author in any work or product based on this material.
23  *
24  * ===========================================================================
25  *
26  */
27 
28 /// @file Search_func.hpp
29 /// User-defined methods of the data storage class.
30 ///
31 /// This file was originally generated by application DATATOOL
32 /// using the following specifications:
33 /// 'macro.asn'.
34 ///
35 /// New methods or data members can be added to it if needed.
36 /// See also: Search_func_.hpp
37 
38 
39 #ifndef OBJECTS_MACRO_SEARCH_FUNC_HPP
40 #define OBJECTS_MACRO_SEARCH_FUNC_HPP
41 
42 
43 // generated includes
48 
49 
50 // generated classes
51 
53 
54 BEGIN_objects_SCOPE // namespace ncbi::objects::
55 
56 /////////////////////////////////////////////////////////////////////////////
58 {
60 public:
63 
64  bool Empty() const;
65  bool Match(const CMatchString& str) const;
66  string GetRegex() const;
67 
68 private:
69  // Prohibit copy constructor and assignment operator
72 
73  // e_Contains_plural
74  bool x_StringMayContainPlural(const string& str) const;
75  bool x_DoesStrContainPlural(const string& word,
76  char last_letter,
77  char second_to_last_letter,
78  char next_letter) const;
79 
80  // e_N_or_more_brackets_or_parentheses
82  const int& n) const;
83  char x_GetClose(char bp) const;
84  bool x_SkipBracketOrParen(size_t idx, string& start) const;
85 
86  // e_Three_numbers
87  bool x_ContainsThreeOrMoreNumbersTogether(const string& str) const;
88  bool x_FollowedByFamily(string& after_str) const;
89  bool x_PrecededByOkPrefix (const string& start_str) const;
90  bool x_InWordBeforeCytochromeOrCoenzyme(const string& start_str) const;
91 
92  // e_Underscore
93  bool x_StringContainsUnderscore(const string& str) const;
94 
95  // e_Prefix_and_numbers
96  bool x_IsPrefixPlusNumbers(const string& str, const string& prefix) const;
97 
98  // e_Unbalanced_paren
99  bool x_StringContainsUnbalancedParentheses(const string& str) const;
100  bool x_IsPropClose(const string& str, char open_p) const;
101 
102  // e_Has_term
103  bool x_ProductContainsTerm(const string& str, const string& pattern) const;
104 };
105 
106 END_objects_SCOPE // namespace ncbi::objects::
108 #endif // OBJECTS_MACRO_SEARCH_FUNC_HPP
Data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
CSearch_func_Base –.
bool x_ProductContainsTerm(const string &str, const string &pattern) const
char x_GetClose(char bp) const
bool x_IsPrefixPlusNumbers(const string &str, const string &prefix) const
bool Match(const CMatchString &str) const
bool x_StringMayContainPlural(const string &str) const
Definition: Search_func.cpp:86
CSearch_func_Base Tparent
Definition: Search_func.hpp:59
CSearch_func & operator=(const CSearch_func &value)
bool Empty() const
Definition: Search_func.cpp:52
bool x_DoesStrContainPlural(const string &word, char last_letter, char second_to_last_letter, char next_letter) const
Definition: Search_func.cpp:65
bool x_ContainsNorMoreSetsOfBracketsOrParentheses(const string &str, const int &n) const
CSearch_func(const CSearch_func &value)
bool x_SkipBracketOrParen(size_t idx, string &start) const
bool x_ContainsThreeOrMoreNumbersTogether(const string &str) const
bool x_StringContainsUnbalancedParentheses(const string &str) const
bool x_InWordBeforeCytochromeOrCoenzyme(const string &start_str) const
bool x_IsPropClose(const string &str, char open_p) const
string GetRegex() const
bool x_StringContainsUnderscore(const string &str) const
bool x_PrecededByOkPrefix(const string &start_str) const
bool x_FollowedByFamily(string &after_str) const
static const char * str(char *buf, int n)
Definition: stats.c:84
#define END_NCBI_SCOPE
End previously defined NCBI scope.
Definition: ncbistl.hpp:103
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
Definition: ncbistl.hpp:100
yy_size_t n
const GenericPointer< typename T::ValueType > T2 value
Definition: pointer.h:1227
static const char * prefix[]
Definition: pcregrep.c:405
Modified on Fri Jul 19 17:17:03 2024 by modify_doxy.py rev. 669887