hce-node application
1.4.3
HCE Hierarchical Cluster Engine node application
Main Page
Namespaces
Classes
Files
File List
File Members
hce-node application
HCE project node model
Namespaces
Classes
Files
File List
sources
src
utils
algorithms
applicationFramework
asmXMLParser
base64
coreDumpChecker
DRCE
exec
HCECSM
jsonObjExtractor
kvdb
messageStream
reduceAdditionCore
reduceCore
reduceDRCE
reduceHandler
reduceSphinx
refine
serializable
sphinx
samples
src
SphinxAdminCommand.cpp
SphinxAdminCommand.hpp
SphinxConfigCreator.cpp
SphinxConfigCreator.hpp
SphinxConfigOptions.cpp
SphinxConfigOptions.hpp
SphinxDataFile.cpp
SphinxDataFile.hpp
SphinxDataSource.cpp
SphinxDataSource.hpp
SphinxDataSourceParameters.cpp
SphinxDataSourceParameters.hpp
SphinxError.hpp
SphinxFilters.cpp
SphinxFilters.hpp
SphinxFunctionalObject.cpp
SphinxFunctionalObject.hpp
SphinxIndexer.cpp
SphinxIndexer.hpp
SphinxInputJsonMessage.cpp
SphinxInputJsonMessage.hpp
SphinxInputJsonMessageIndex.cpp
SphinxInputJsonMessageIndex.hpp
SphinxInputJsonMessageManage.cpp
SphinxInputJsonMessageManage.hpp
SphinxInputJsonMessageSearch.cpp
SphinxInputJsonMessageSearch.hpp
SphinxMatchInfo.cpp
SphinxMatchInfo.hpp
SphinxMessageConst.hpp
SphinxNodeOptions.cpp
SphinxNodeOptions.hpp
SphinxOutputJsonMessage.cpp
SphinxOutputJsonMessage.hpp
SphinxRequestInfo.cpp
SphinxRequestInfo.hpp
SphinxResultData.cpp
SphinxResultData.hpp
SphinxResultDataItem.hpp
SphinxResultDataMemoryManager.cpp
SphinxResultDataMemoryManager.hpp
SphinxResultDataSerializator.cpp
SphinxResultDataSerializator.hpp
SphinxSchemaFile.cpp
SphinxSchemaFile.hpp
SphinxSearcher.cpp
SphinxSearcher.hpp
SphinxSearchInterface.cpp
SphinxSearchInterface.hpp
SphinxWeightCalculator.cpp
SphinxWeightCalculator.hpp
tests
types
xmlCleaner
File Members
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
SphinxMatchInfo.hpp
Go to the documentation of this file.
1
14
#ifndef SPHINX_MATCH_INFO_HPP
15
#define SPHINX_MATCH_INFO_HPP
16
17
#include <vector>
18
19
#include "
SphinxResultDataItem.hpp
"
20
21
namespace
HCE
22
{
23
namespace
sphinx
24
{
25
//-----------------------------------------------------------------------------
26
struct
AttrInfo
27
{
28
AttrInfo
(
void
) :
name
(
""
),
value
(
""
) {}
29
AttrInfo
(
const
std::string& name_,
const
std::string& value_) :
name
(name_),
value
(value_) {}
30
AttrInfo
(
const
AttrInfo
& rhs);
31
AttrInfo
(
AttrInfo
&& rhs);
32
33
AttrInfo
&
operator=
(
const
AttrInfo
& rhs);
34
AttrInfo
&
operator=
(
AttrInfo
&& rhs);
35
36
std::string
name
;
37
std::string
value
;
38
};
39
//-----------------------------------------------------------------------------
40
class
SphinxMatchInfo
41
{
42
enum
{STRING_LENGTH=20};
43
public
:
44
SphinxMatchInfo
(
void
);
45
explicit
SphinxMatchInfo
(
size_t
attributesCount
);
46
SphinxMatchInfo
(
const
SphinxMatchInfo
& rhs);
47
SphinxMatchInfo
(
SphinxMatchInfo
&& rhs);
48
~SphinxMatchInfo
(
void
) {}
49
50
SphinxMatchInfo
&
operator=
(
const
SphinxMatchInfo
& rhs);
51
SphinxMatchInfo
&
operator=
(
SphinxMatchInfo
&& rhs);
52
53
void
setDocId
(
unsigned
long
long
docId_) {docId = docId_;}
54
unsigned
long
long
getDocId
(
void
)
const
{
return
docId;}
55
private
:
56
void
setWeight(
const
std::string& weight_) {weight = weight_;}
57
public
:
58
std::string
getWeight
(
void
)
const
{
return
weight;}
59
void
setWeightFromNumeric
(
unsigned
long
long
weight,
unsigned
long
long
length= STRING_LENGTH);
60
void
setWeightFromHexString
(
const
std::string& weight);
61
void
setWeightFromDecString
(
const
std::string& weight,
unsigned
long
long
length=STRING_LENGTH);
62
63
void
addAttrInfo
(
const
AttrInfo
& attrInfo);
64
void
addAttrInfo
(
AttrInfo
&& attrInfo);
65
void
addAttrInfo
(
const
std::string&
name
,
const
std::string& value);
66
67
const
std::vector<SphinxResultDataItem<AttrInfo> >&
getAttributes
(
void
)
const
{
return
attributes;}
68
const
AttrInfo
getFieldByName
(
const
std::string& attrName)
const
;
69
70
size_t
getAttributesCount
(
void
)
const
;
71
const
AttrInfo
&
getAttrItem
(
size_t
index
)
const
;
72
void
setAttrItem
(
size_t
index
,
const
AttrInfo
& attr);
73
void
setAttrItem
(
size_t
index
,
AttrInfo
&& attr);
74
75
void
clear
(
void
);
76
void
reset
(
void
);
77
void
resize
(
size_t
sz
);
78
private
:
79
unsigned
long
long
docId;
80
std::string weight;
81
std::vector<SphinxResultDataItem<AttrInfo> > attributes;
82
83
friend
class
SphinxResultDataMemoryManager
;
84
friend
class
CalculateStrategyDefault
;
85
friend
class
CalculateStrategyUseFieldNames
;
86
};
87
//-----------------------------------------------------------------------------
88
//-----------------------------------------------------------------------------
89
}
// namespace sphinx
90
}
// namespace HCE
91
92
#endif // SPHINX_MATCH_INFO_HPP
sources
utils
sphinx
src
SphinxMatchInfo.hpp
Generated on Tue Jun 30 2015 19:42:17 for hce-node application by
1.8.1.2