本文整理汇总了C++中std::initializer_list::begin方法的典型用法代码示例。如果您正苦于以下问题:C++ initializer_list::begin方法的具体用法?C++ initializer_list::begin怎么用?C++ initializer_list::begin使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类std::initializer_list
的用法示例。
在下文中一共展示了initializer_list::begin方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: key_qvalue_pairs
inline std::string key_qvalue_pairs(std::initializer_list<kv_pair> pairs)
{
return key_qvalue_pairs(array_view<kv_pair>{pairs.begin(), pairs.end()});
}
示例2: callAsFunction
Value Object::callAsFunction(const Object& thisObj, std::initializer_list<JSValueRef> args) const {
return callAsFunction((JSObjectRef)thisObj, args.size(), args.begin());
}
示例3: operator
constexpr
ranges::reverse_iterator<T const*> operator()(std::initializer_list<T> il) const noexcept
{
return ranges::reverse_iterator<T const*>(il.begin());
}
示例4: in
inline bool in(std::initializer_list<file_type> types, file_type value) {
return find(types.begin(), types.end(), value) != types.end();
}
示例5: add
void add(std::initializer_list<AssemblyStage*> stages) {
for (auto it = stages.begin(), et = stages.end(); it != et; ++it)
add(*it);
}
示例6: lstring
inline lstring::lstring(std::initializer_list<string> list) {
for(const string *s = list.begin(); s != list.end(); ++s) {
operator<<(*s);
}
}
示例7: set
//! <b>Effects</b>: Constructs an empty set using the specified
//! allocator, and inserts elements from the range [il.begin(), il.end()).
//!
//! <b>Complexity</b>: Linear in N if the range [il.begin(), il.end()) is already sorted using
//! comp and otherwise N logN, where N is il.begin() - il.end().
set(std::initializer_list<value_type> il, const allocator_type& a)
: base_t(true, il.begin(), il.end(), Compare(), a)
{}
示例8: Assign
void Assign(std::initializer_list<Char> rhs) noexcept {
Assign(rhs.begin(), rhs.end());
}
示例9:
inline Heap<T, Compare>::Heap(std::initializer_list<T> list):
Heap<T, Compare>(list.begin(), list.end())
{}
示例10:
// initializer_list constuctor
segmented_map(std::initializer_list<value_type> il) : segmented_map{il.begin(), il.end()} {}
示例11: StringObserver
constexpr StringObserver(std::initializer_list<Char> rhs) noexcept
: StringObserver(rhs.begin(), rhs.size())
{
}
示例12: Polygon
explicit Polygon(std::initializer_list<Vec2> outer)
: Polygon(outer.begin(), outer.size()) {}
示例13: Z
Z(std::initializer_list<int> il) : i_(il.begin()[0]), j_(il.begin()[1])
{ TEST_THROW(6);}
示例14: Y
constexpr Y(std::initializer_list<int> il) : i_(il.begin()[0]), j_(il.begin()[1]) {}
示例15: CompareF
flat_map(
std::initializer_list<value_type> init,
CompareF const &comp = CompareF(),
Alloc const &a = Alloc()
) : flat_map(init.begin(), init.end(), comp, a)
{}