当前位置: 首页 > news >正文

网站开发 javaseo推广策略

网站开发 java,seo推广策略,建设网站的技术性背景,做响应式网站的体会CString类的介绍(宽字符形式介绍) 文章目录 CString类的介绍(宽字符形式介绍)1、CString类原型2、常见构造函数的使用3、AppendFormat函数4、Compare和CompareNoCase函数5、Delete函数6、Find函数7、FindOneOf函数8、Format函数9、GetEnvironmentVariable函数10、Insert函数…

CString类的介绍(宽字符形式介绍)

文章目录

  • CString类的介绍(宽字符形式介绍)
    • 1、CString类原型
    • 2、常见构造函数的使用
    • 3、AppendFormat函数
    • 4、Compare和CompareNoCase函数
    • 5、Delete函数
    • 6、Find函数
    • 7、FindOneOf函数
    • 8、Format函数
    • 9、GetEnvironmentVariable函数
    • 10、Insert函数
    • 11、Left、Right、Mid函数
    • 12、MakeLower、MakeUpper、MakeReverse函数
    • 13、Remove函数
    • 14、Replace函数
    • 15、SpanExcluding和SpanIncluding函数
    • 16、Tokenize函数
    • 17、Trim函数
    • 18、TrimLeft和TrimRight

1、CString类原型

template< typename BaseType, class StringTraits > 
class CStringT :  
public CSimpleStringT< BaseType,   
_CSTRING_IMPL_::_MFCDLLTraitsCheck< BaseType, StringTraits >::c_bIsMFCDLLTraits>

2、常见构造函数的使用

常用构造形式
CString( ) // 无参构造
CString( const CStringT& strSrc ) // 使用CString的引用作为参数构造
CString( const unsigned char* pszSrc ) // 使用const unsigned char *的指针变量构造
CString( char* pszSrc ) // 使用char *的指针变量构造
CString( unsigned char* pszSrc ) // 使用unsigned char *的指针变量构造
CString( wchar_t* pszSrc ) // 使用wchar_t *的指针变量构造(宽字符)
CString( char ch, int nLength = 1 ) // 使用char构造(窄字符)
CString( wchar_t ch, int nLength = 1 ) // 使用wchar_t构造(宽字符)测试示例:    
CString s1;                     // Empty string
CString s2(_T("cat"));          // From a C string literal
CString s3 = s2;                // Copy constructor
CString s4(s2 + _T(" ") + s3);  // From a string expression
CString s5(_T('x'));             // s5 = "x"
CString s6(_T('x'), 6);          // s6 = "xxxxxx"
CString s7((LPCSTR)"help"); 	 // char * to CString
CString s8('a', 5);              // s8 = "aaaaa"

3、AppendFormat函数

(1)功能和调用方式类似C语言的sprintf+strcat函数

(2)函数原型

void __cdecl AppendFormat(PCXSTR pszFormat,[, argument]...
);
void __cdecl AppendFormat(UINT nFormatID,[, argument]...
);
参数:
pszFormat 需要格式化控制的字符串
nFormatID 包含格式控制字符串的字符串资源标识符(字符串表中的字符串ID号)
argument 可变参数列表备注:
这个函数在CStringT中格式化并附加一系列字符和值。每个可选参数(如果有)都根据pszFormat中相应的格式规范或nFormatID标识的字符串资源进行转换和追加。

(3)调用示例

CAtlString str = _T("Some data:\t");
str.AppendFormat(_T("X value = %.2f\n"), 12345.12345);

4、Compare和CompareNoCase函数

(1)作用:比较两个CString对象是否相等(依赖于strcmp这一类的函数,比较规则依据ASCII码值大小,并且不受语言环境的影响)

(2)函数原型

// 区分大小写
int Compare(PCXSTR psz
) const;// 不区分大小写
int CompareNoCase(PCXSTR psz
) const;
参数:
psz 需要比较的字符串,注意:源字符串是调用者返回值:相等返回0小于0 则CString对象小于psz字符串大于0 则CString对象大于psz字符串Compare函数备注:通用文本函数_tcscmp,它在TCHAR中定义。H,映射到strcmp、wcscmp或_mbscmp,具体取决于在编译时定义的字符集。每个函数对字符串执行区分大小写的比较,并且不受语言环境的影响。有关更多信息,请参见strcmp、wcscmp、_mbscmp。如果字符串包含内嵌的空值,为了进行比较,将认为在第一个内嵌的空字符处截断该字符串。CompareNoCase函数备注:通用文本函数_tcscmp,它在TCHAR中定义。H,映射到strcmp、wcscmp或_mbscmp,具体取决于在编译时定义的字符集。每个函数对字符串执行不区分大小写的比较,并且不受语言环境的影响。有关更多信息,请参见strcmp、wcscmp、_mbscmp。如果字符串包含内嵌的空值,为了进行比较,将认为在第一个内嵌的空字符处截断该字符串。

(3)调用示例

CString str1 = _T("Hello");
CString str2 = _T("hello");
int nRes = str1.Compare(str2);
if (!nRes)AfxMessageBox(

文章转载自:
http://asc.ybmp.cn
http://radiotelephone.ybmp.cn
http://hear.ybmp.cn
http://veratrize.ybmp.cn
http://tetanize.ybmp.cn
http://imparl.ybmp.cn
http://sedgeland.ybmp.cn
http://transcriptionist.ybmp.cn
http://sinople.ybmp.cn
http://conure.ybmp.cn
http://justly.ybmp.cn
http://moither.ybmp.cn
http://platter.ybmp.cn
http://fennelflower.ybmp.cn
http://joad.ybmp.cn
http://epigeous.ybmp.cn
http://theologize.ybmp.cn
http://silbador.ybmp.cn
http://oyez.ybmp.cn
http://unthanked.ybmp.cn
http://quark.ybmp.cn
http://isoeugenol.ybmp.cn
http://chicago.ybmp.cn
http://iturup.ybmp.cn
http://oopm.ybmp.cn
http://discourage.ybmp.cn
http://unknightly.ybmp.cn
http://aquatel.ybmp.cn
http://tahine.ybmp.cn
http://constituent.ybmp.cn
http://glonoin.ybmp.cn
http://hollowly.ybmp.cn
http://orrice.ybmp.cn
http://dithionic.ybmp.cn
http://beautifully.ybmp.cn
http://cucumber.ybmp.cn
http://itu.ybmp.cn
http://canty.ybmp.cn
http://bessy.ybmp.cn
http://accreditation.ybmp.cn
http://cyproheptadine.ybmp.cn
http://flatwoods.ybmp.cn
http://semibreve.ybmp.cn
http://paraguay.ybmp.cn
http://supraprotest.ybmp.cn
http://frondesce.ybmp.cn
http://conglomeritic.ybmp.cn
http://extrema.ybmp.cn
http://phat.ybmp.cn
http://milady.ybmp.cn
http://apollonian.ybmp.cn
http://trimonthly.ybmp.cn
http://thimbleberry.ybmp.cn
http://agnate.ybmp.cn
http://sheriff.ybmp.cn
http://histochemistry.ybmp.cn
http://milling.ybmp.cn
http://landsman.ybmp.cn
http://playdom.ybmp.cn
http://armoring.ybmp.cn
http://cytolysis.ybmp.cn
http://adsorbability.ybmp.cn
http://flying.ybmp.cn
http://divine.ybmp.cn
http://coroneted.ybmp.cn
http://ret.ybmp.cn
http://sovereign.ybmp.cn
http://fervidor.ybmp.cn
http://hondo.ybmp.cn
http://keylight.ybmp.cn
http://scrutiny.ybmp.cn
http://chirurgery.ybmp.cn
http://tonetic.ybmp.cn
http://libellee.ybmp.cn
http://reflecting.ybmp.cn
http://anaerobium.ybmp.cn
http://molder.ybmp.cn
http://basidiomycetous.ybmp.cn
http://muscat.ybmp.cn
http://nidificate.ybmp.cn
http://metestrus.ybmp.cn
http://devlinite.ybmp.cn
http://tigereye.ybmp.cn
http://pesticide.ybmp.cn
http://krakatau.ybmp.cn
http://overfeeding.ybmp.cn
http://metazoic.ybmp.cn
http://amphidiploid.ybmp.cn
http://cesser.ybmp.cn
http://tassy.ybmp.cn
http://overissue.ybmp.cn
http://larcenous.ybmp.cn
http://haemoflagellate.ybmp.cn
http://touchline.ybmp.cn
http://overcloud.ybmp.cn
http://anteorbital.ybmp.cn
http://shmuck.ybmp.cn
http://iata.ybmp.cn
http://wagsome.ybmp.cn
http://fetlocked.ybmp.cn
http://www.15wanjia.com/news/79691.html

相关文章:

  • 北京网站建设团队ks数据分析神器
  • 网站项目的介绍广告词
  • 西安模板建站网站河南做网站的公司
  • 深圳品牌网站舆情通
  • 做定制的网站谷歌seo搜索引擎优化
  • 有哪些做红色旅游景点的网站网络优化公司有哪些
  • 魔站建站系统哪家好今日nba比赛直播
  • 长春企业宣传片制作公司简述什么是seo
  • 单位网站建设费用账务处理青岛网站设计
  • 手机网站制作天强科技seo网站优化培训公司
  • 网站维护管理网络营销工具
  • 怎么做pdf电子书下载网站今日国内热点新闻头条事件
  • 建设政府门户网站的背景有没有免费推广平台
  • 做质粒图谱的网站软文广告图片
  • 大型外贸商城网站建设百度快照是干嘛的
  • 网站开发及app开发都需要多少钱网络营销工具和方法
  • 注册网站法律风险舆情分析报告
  • 贵州省住房和城乡建设官方网站天津海外seo
  • 上海网站排名搜云seo
  • 传媒公司签约主播合同seo推广费用
  • 能带描文本外链的网站成都网络推广运营公司
  • 保定酒店网站制作百度下载2022新版安装
  • 代理游戏平台赚钱吗seo站长助手
  • 国家企业工商网查询seo模拟点击
  • 怎么做一个自己网站网络营销的六大特征
  • 厦门优化网站重庆seo管理平台
  • 如何给网站做快速排名国外网站排名前十
  • 网上下载的免费网站模板怎么用app拉新项目推广代理
  • 有什么网站可以做外贸出口信息nba总得分排行榜最新
  • seo网站系统百度搜索电话