本文整理汇总了C++中value_type::insert方法的典型用法代码示例。如果您正苦于以下问题:C++ value_type::insert方法的具体用法?C++ value_type::insert怎么用?C++ value_type::insert使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类value_type
的用法示例。
在下文中一共展示了value_type::insert方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: insert_into_view_arg
inline void insert_into_view_arg(value_type& dest, const arg_type& arg) {
typedef typename polygon_set_traits<arg_type>::iterator_type literator;
literator itr1, itr2;
itr1 = polygon_set_traits<arg_type>::begin(arg);
itr2 = polygon_set_traits<arg_type>::end(arg);
dest.insert(itr1, itr2);
}
示例2: execute_boolean_op
void execute_boolean_op(value_type& output_, const geometry_type_1& lvalue_, const geometry_type_2& rvalue_) {
typedef geometry_type_1 ltype;
typedef geometry_type_2 rtype;
typedef typename polygon_set_traits<ltype>::coordinate_type coordinate_type;
value_type linput_;
value_type rinput_;
insert_into_view_arg(linput_, lvalue_);
insert_into_view_arg(rinput_, rvalue_);
polygon_45_set_data<coordinate_type> l45, r45, o45;
if(linput_.downcast(l45) && rinput_.downcast(r45)) {
//the op codes are screwed up between 45 and arbitrary
#ifdef BOOST_POLYGON_MSVC
#pragma warning (disable: 4127)
#endif
if(op_type < 2)
l45.template applyAdaptiveBoolean_<op_type>(o45, r45);
else if(op_type == 2)
l45.template applyAdaptiveBoolean_<3>(o45, r45);
else
l45.template applyAdaptiveBoolean_<2>(o45, r45);
#ifdef BOOST_POLYGON_MSVC
#pragma warning (default: 4127)
#endif
output_.insert(o45);
} else {
arbitrary_boolean_op<coordinate_type> abo;
abo.execute(output_, linput_.begin(), linput_.end(),
rinput_.begin(), rinput_.end(), op_type);
}
}
示例3: operator
void operator()(FeatureType & f, uint32_t)
{
++m_totalCount;
string s1, s2;
f.GetPreferredNames(s1, s2);
if (!s1.empty())
++m_namesCount;
m_currFeatureTypes.clear();
f.ForEachType([this](uint32_t type)
{
m_currFeatureTypes.push_back(type);
});
CHECK(!m_currFeatureTypes.empty(), ("Feature without any type???"));
auto found = m_stats.insert(make_pair(m_currFeatureTypes, 1));
if (!found.second)
found.first->second++;
}
示例4: add
enumtype* add(int enumo,const char* sym)
{
values.insert(std::make_pair(enumo,rb_intern(sym)));
return this;
}