189 lines
8.8 KiB
HTML
189 lines
8.8 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
|
<meta name="generator" content="Doxygen 1.8.6"/>
|
|
<title>Boost.Locale: boost::locale::comparator< CharType, default_level > Struct Template Reference</title>
|
|
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="jquery.js"></script>
|
|
<script type="text/javascript" src="dynsections.js"></script>
|
|
<link href="navtree.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="resize.js"></script>
|
|
<script type="text/javascript" src="navtree.js"></script>
|
|
<script type="text/javascript">
|
|
$(document).ready(initResizable);
|
|
$(window).load(resizeHeight);
|
|
</script>
|
|
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
</head>
|
|
<body>
|
|
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
<div id="titlearea">
|
|
<table cellspacing="0" cellpadding="0">
|
|
<tbody>
|
|
<tr style="height: 56px;">
|
|
<td id="projectlogo"><img alt="Logo" src="boost-small.png"/></td>
|
|
<td style="padding-left: 0.5em;">
|
|
<div id="projectname">Boost.Locale
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
<!-- end header part -->
|
|
<!-- Generated by Doxygen 1.8.6 -->
|
|
<div id="navrow1" class="tabs">
|
|
<ul class="tablist">
|
|
<li><a href="index.html"><span>Main Page</span></a></li>
|
|
<li><a href="pages.html"><span>Related Pages</span></a></li>
|
|
<li><a href="modules.html"><span>Modules</span></a></li>
|
|
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
|
|
<li class="current"><a href="annotated.html"><span>Classes</span></a></li>
|
|
<li><a href="files.html"><span>Files</span></a></li>
|
|
<li><a href="examples.html"><span>Examples</span></a></li>
|
|
</ul>
|
|
</div>
|
|
<div id="navrow2" class="tabs2">
|
|
<ul class="tablist">
|
|
<li><a href="annotated.html"><span>Class List</span></a></li>
|
|
<li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li>
|
|
<li><a href="functions.html"><span>Class Members</span></a></li>
|
|
</ul>
|
|
</div>
|
|
</div><!-- top -->
|
|
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
|
<div id="nav-tree">
|
|
<div id="nav-tree-contents">
|
|
<div id="nav-sync" class="sync"></div>
|
|
</div>
|
|
</div>
|
|
<div id="splitbar" style="-moz-user-select:none;"
|
|
class="ui-resizable-handle">
|
|
</div>
|
|
</div>
|
|
<script type="text/javascript">
|
|
$(document).ready(function(){initNavTree('structboost_1_1locale_1_1comparator.html','');});
|
|
</script>
|
|
<div id="doc-content">
|
|
<div class="header">
|
|
<div class="summary">
|
|
<a href="#pub-methods">Public Member Functions</a> |
|
|
<a href="structboost_1_1locale_1_1comparator-members.html">List of all members</a> </div>
|
|
<div class="headertitle">
|
|
<div class="title">boost::locale::comparator< CharType, default_level > Struct Template Reference<div class="ingroups"><a class="el" href="group__collation.html">Collation</a></div></div> </div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
|
|
<p>This class can be used in STL algorithms and containers for comparison of strings with a level other than primary.
|
|
<a href="structboost_1_1locale_1_1comparator.html#details">More...</a></p>
|
|
|
|
<p><code>#include <<a class="el" href="collator_8hpp_source.html">boost/locale/collator.hpp</a>></code></p>
|
|
<table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
|
|
Public Member Functions</h2></td></tr>
|
|
<tr class="memitem:af40ee48c6c93b6e5d91492a3e0cb96a8"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="structboost_1_1locale_1_1comparator.html#af40ee48c6c93b6e5d91492a3e0cb96a8">comparator</a> (std::locale const &l=std::locale(), <a class="el" href="classboost_1_1locale_1_1collator__base.html#a73c12de809733273304fef7f0af28b22">collator_base::level_type</a> level=default_level)</td></tr>
|
|
<tr class="separator:af40ee48c6c93b6e5d91492a3e0cb96a8"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:abd62dbc2af0eb6e6c261a7c88e09f752"><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="structboost_1_1locale_1_1comparator.html#abd62dbc2af0eb6e6c261a7c88e09f752">operator()</a> (std::basic_string< CharType > const &left, std::basic_string< CharType > const &right) const </td></tr>
|
|
<tr class="separator:abd62dbc2af0eb6e6c261a7c88e09f752"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table>
|
|
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
|
|
<div class="textblock"><h3>template<typename CharType, collator_base::level_type default_level = collator_base::identical><br/>
|
|
struct boost::locale::comparator< CharType, default_level ></h3>
|
|
|
|
<p>This class can be used in STL algorithms and containers for comparison of strings with a level other than primary. </p>
|
|
<p>For example:</p>
|
|
<div class="fragment"><div class="line">std::map<std::string,std::string,comparator<char,collator_base::secondary> > data;</div>
|
|
</div><!-- fragment --><p>Would create a map the keys of which are sorted using secondary collation level </p>
|
|
</div><h2 class="groupheader">Constructor & Destructor Documentation</h2>
|
|
<a class="anchor" id="af40ee48c6c93b6e5d91492a3e0cb96a8"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<div class="memtemplate">
|
|
template<typename CharType , collator_base::level_type default_level = collator_base::identical> </div>
|
|
<table class="mlabels">
|
|
<tr>
|
|
<td class="mlabels-left">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname"><a class="el" href="structboost_1_1locale_1_1comparator.html">boost::locale::comparator</a>< CharType, default_level >::<a class="el" href="structboost_1_1locale_1_1comparator.html">comparator</a> </td>
|
|
<td>(</td>
|
|
<td class="paramtype">std::locale const & </td>
|
|
<td class="paramname"><em>l</em> = <code>std::locale()</code>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype"><a class="el" href="classboost_1_1locale_1_1collator__base.html#a73c12de809733273304fef7f0af28b22">collator_base::level_type</a> </td>
|
|
<td class="paramname"><em>level</em> = <code>default_level</code> </td>
|
|
</tr>
|
|
<tr>
|
|
<td></td>
|
|
<td>)</td>
|
|
<td></td><td></td>
|
|
</tr>
|
|
</table>
|
|
</td>
|
|
<td class="mlabels-right">
|
|
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
<p>Create a comparator class for locale <em>l</em> and with collation leval <em>level</em> </p>
|
|
<dl class="section note"><dt>Note</dt><dd>throws std::bad_cast if l does not have <a class="el" href="classboost_1_1locale_1_1collator.html">collator</a> facet installed </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<h2 class="groupheader">Member Function Documentation</h2>
|
|
<a class="anchor" id="abd62dbc2af0eb6e6c261a7c88e09f752"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<div class="memtemplate">
|
|
template<typename CharType , collator_base::level_type default_level = collator_base::identical> </div>
|
|
<table class="mlabels">
|
|
<tr>
|
|
<td class="mlabels-left">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">bool <a class="el" href="structboost_1_1locale_1_1comparator.html">boost::locale::comparator</a>< CharType, default_level >::operator() </td>
|
|
<td>(</td>
|
|
<td class="paramtype">std::basic_string< CharType > const & </td>
|
|
<td class="paramname"><em>left</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">std::basic_string< CharType > const & </td>
|
|
<td class="paramname"><em>right</em> </td>
|
|
</tr>
|
|
<tr>
|
|
<td></td>
|
|
<td>)</td>
|
|
<td></td><td> const</td>
|
|
</tr>
|
|
</table>
|
|
</td>
|
|
<td class="mlabels-right">
|
|
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
<p>Compare two strings – equivalent to return left < right according to collation rules </p>
|
|
|
|
</div>
|
|
</div>
|
|
<hr/>The documentation for this struct was generated from the following file:<ul>
|
|
<li>boost/locale/<a class="el" href="collator_8hpp_source.html">collator.hpp</a></li>
|
|
</ul>
|
|
</div><!-- contents -->
|
|
</div><!-- doc-content -->
|
|
|
|
<li class="footer">
|
|
© Copyright 2009-2012 Artyom Beilis, Distributed under the <a href="http://www.boost.org/LICENSE_1_0.txt">Boost Software License</a>, Version 1.0.
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
</body>
|
|
</html>
|