描述符的使用
来源:互联网 发布:rice university 知乎 编辑:程序博客网 时间:2024/04/29 17:08
void HelloWorldL()
{
const TInt KHelloWorldLength = 14;
TBuf<KHelloWorldLength> tbuf(KTextHelloWorld);
TBufC<KHelloWorldLength> tbufc(KTextHelloWorld);
HBufC* hbufc = KTextHelloWorld().AllocLC();
RBuf rbuf;
rbuf.CreateL(KTextHelloWorld,KHelloWorldLength);
rbuf.CleanupClosePushL();
TPtrC tptrc(tbufc);
TPtr tptr = hbufc->Des();
console->Printf(KTextHelloWorld);
console->Printf(tbuf);
console->Printf(tbufc);
console->Printf(tptr);
console->Printf(tptrc);
console->Printf(*hbufc);
console->Printf(rbuf);
CleanupStack::PopAndDestroy(2);
}
void Func1()
{
TBuf<20> bufHelloWorld(KTextHello);
_LIT(KString1,"The original string is /"%s/"/n");
console->Printf(KString1,&bufHelloWorld);
bufHelloWorld.Append(KTextWorld);
_LIT(KString2,"The modifed string is /"%s/"/n");
console->Printf(KString2,&bufHelloWorld);
bufHelloWorld.LowerCase();//转换为小写
_LIT(KString3,"The lowercase of the string is /"%s/"/n");
console->Printf(KString3,&bufHelloWorld);
bufHelloWorld.UpperCase();//转换为大写
_LIT(KString4,"The uppercase of the string is /"%s/"/n");
console->Printf(KString4,&bufHelloWorld);
}
- 描述符的使用
- 文件描述符&write函数的使用
- 使用描述符API
- CSS属性的使用描述
- Symbian中字符串描述符的使用编程
- 关于接口描述符中bAlternateSetting的使用
- 关于接口描述符中bAlternateSetting的使用
- select及相关文件描述符集的使用
- 关于接口描述符中bAlternateSetting的使用
- 对象属性管理和描述符的使用
- 文件描述符存在形式及其dup2函数的使用
- linux下查看进程使用文件描述符的详细信息
- GIST特征描述符使用
- GIST特征描述符使用
- GIST特征描述符使用
- GIST特征描述符使用
- 描述符的总结
- 描述符的总结
- Win7让你的程序变得更加漂亮,同样的程序在Win7操作系统下的效果对比
- Ecache 缓存
- xxx
- window_open详解
- CSS
- 描述符的使用
- MySQL练习
- SHUX
- 软件公司做现金管理的危机与方向
- 《WCF技术内幕》翻译25:第2部分_第5章_消息:创建一个消息(下)之MessageFault
- 一本聽說可以帶來幸福的書
- get_magic_quotes_gpc()是做什么的 get_magic_quotes_gpc用法
- 硬件知识——主板结构
- 专访威廉.皮诺