当前位置: 首页>>代码示例>>C++>>正文


C++ this_type::size方法代码示例

本文整理汇总了C++中this_type::size方法的典型用法代码示例。如果您正苦于以下问题:C++ this_type::size方法的具体用法?C++ this_type::size怎么用?C++ this_type::size使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在this_type的用法示例。


在下文中一共展示了this_type::size方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1:

	BStr::BStr(const this_type & val) :
		m_str(nullptr)
	{
		if (val.m_str) {
			m_str = ::SysAllocStringLen(val.m_str, val.size());
			if (!m_str)
				CheckCom(E_OUTOFMEMORY);
		}
	}
开发者ID:IDA-RE-things,项目名称:andrew-grechkin,代码行数:9,代码来源:bstr.cpp

示例2: compare

 /*!
  * Lexicographically compares the argument string to this string
  *
  * \param that Comparand
  * \return Zero if the comparand equals this string, a negative value if this string is less than the comparand,
  *         a positive value if this string is greater than the comparand.
  */
 int compare(this_type const& that) const
 {
     return compare(0, m_Len, that.c_str(), that.size());
 }
开发者ID:nairboon,项目名称:anarchnet,代码行数:11,代码来源:string_literal.hpp

示例3:

 friend bool operator==(const this_type& l, const this_type& r)
 {
     return l.size() == r.size() &&
            ngx_strncmp(l.data(), r.data(), l.size()) == 0
         ;
 }
开发者ID:ZCXL,项目名称:ngx_cpp_dev,代码行数:6,代码来源:NgxString.hpp


注:本文中的this_type::size方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。