<?xml version="1.0" encoding="utf-8"?><?xml-stylesheet href='http://feeds.feedsky.com/styles/temp01.xsl' type='text/xsl' ?><!--这是一个由Feedsy提供技术支持的Feed，为了提高读者阅读的体验，以及满足用户美化自己Feed的需要，我们设计了多种精美的Feed模板，提供给大家选择，所有最终呈现出来的样式，皆由用户自愿选择使用，未经许可，任何团体和个人，请不要擅自修改样式或者盗用，这是对于用户选择权的尊重。--><rss xmlns:atom="http://www.w3.org/2005/Atom" xmlns:fs="http://www.feedsky.com/namespace/feed" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:dc="http://purl.org/dc/elements/1.1/" version="2.0"><channel><atom:link href="http://feeds.feedsky.com/csdn.net/vieri_ch" type="application/rss+xml" rel="self"></atom:link><fs:self_link href="http://feeds.feedsky.com/csdn.net/vieri_ch" type="application/rss+xml"></fs:self_link><lastBuildDate>Fri, 15 Jun 2007 10:25:00 GMT</lastBuildDate><title>尘雨::执着VC</title><description>漠漠轻寒上小楼，晓阴无赖似穷秋。淡军流水画屏幽。自在飞花轻似梦，无边丝雨细如愁。宝帘闲挂小银钩。</description><link>http://blog.csdn.net/vieri_ch/</link><item><title>有些茫然，缺少方向感...破局</title><link>http://blog.csdn.net/vieri_ch/archive/2007/06/15/1653320.aspx</link><wfw:comment>http://blog.csdn.net/vieri_ch/comments/1653320.aspx</wfw:comment><slash:comments>0</slash:comments><wfw:commentRss>http://blog.csdn.net/vieri_ch/comments/commentRss/1653320.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1653320</trackback:ping><description>是该做些什么了，虽然手头有些事情仍然纠缠不清，但是最终努力向前需要打破的仍然是自己的惰性，狭隘性。努力的提高技术能力，做几件完整的事情，是目前最需要的。生活和情绪的羁绊让自己总在原地徘徊，自己需要什么？当一个一个或难或易的技术问题被自己解决，仅仅满足于这个感觉是难以更进一步的。专心，专注，坚持和行动是我打破目前工作僵局的手段。刀放久了，就不再是刀了&lt;img src =&quot;http://blog.csdn.net/vieri_ch/aggbug/1653320.aspx&quot; width = &quot;1&quot; height = &quot;1&quot; /&gt;</description><pubDate>Fri, 15 Jun 2007 18:25:00 +0800</pubDate><author>vieri_ch</author><comments>http://blog.csdn.net/vieri_ch/archive/2007/06/15/1653320.aspx#Feedback</comments><guid isPermaLink="false">http://blog.csdn.net/vieri_ch/archive/2007/06/15/1653320.aspx</guid><dc:creator>vieri_ch</dc:creator></item><item><title>iBatis net的一些心得</title><link>http://blog.csdn.net/vieri_ch/archive/2007/04/03/1550896.aspx</link><wfw:comment>http://blog.csdn.net/vieri_ch/comments/1550896.aspx</wfw:comment><slash:comments>0</slash:comments><wfw:commentRss>http://blog.csdn.net/vieri_ch/comments/commentRss/1550896.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1550896</trackback:ping><description>最近一段时间比较忙，但仍在工作之余摸索和回顾了一下iBatist net 的使用心得和一些问题的解决

本人对面向对象和设计模式的掌握并不深入，文章中的心得和理解不一定十分准确或者符合设计模式的要求。

iBatisnet这个开源框架在类对象和数据库对象之间建立起一种映射和反射的关系，也就是通常所说的ORM，严格来说，应该是类和SQL查询语句之间的映射。与nHibernate相比，他的ORM特性并不彻底。但正是这种不彻底，才更为我所能接受，nhibernate封装了HQL语法来替代标准的SQL,提供了很多类来完成或者描述数据之间的关系，以前，这些都是在数据库设计层，利用数据库的约束等来实现关系。nHibernate的做法更倾向于把数据关系和逻辑放在应用层和OO中，而数据库的角色仅仅是单纯的数据存储，关系和约束以及逻辑都不在数据库表设计阶段出现。而是在设计XML配置文件的时候进行。这与以前的应用系统做法相差较大，而且HQL在很多时候不能取代SQL，其广泛程度更是不能相比。性能问题，以及大量的配置文件始终都是避免不了的问题。。。。

有点跑题了，还是先把一些问题的解决放出来
&lt;img src =&quot;http://blog.csdn.net/vieri_ch/aggbug/1550896.aspx&quot; width = &quot;1&quot; height = &quot;1&quot; /&gt;</description><pubDate>Wed, 04 Apr 2007 01:54:00 +0800</pubDate><author>vieri_ch</author><comments>http://blog.csdn.net/vieri_ch/archive/2007/04/03/1550896.aspx#Feedback</comments><guid isPermaLink="false">http://blog.csdn.net/vieri_ch/archive/2007/04/03/1550896.aspx</guid><dc:creator>vieri_ch</dc:creator></item><item><title>1号信令、7号信令和PRI信令</title><link>http://blog.csdn.net/vieri_ch/archive/2007/03/02/1519541.aspx</link><wfw:comment>http://blog.csdn.net/vieri_ch/comments/1519541.aspx</wfw:comment><slash:comments>0</slash:comments><wfw:commentRss>http://blog.csdn.net/vieri_ch/comments/commentRss/1519541.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1519541</trackback:ping><description>1号信令、7号信令和PRI信令-
按照信令的信道来分类，信令可以分为：随路信令和公共信道信令。 
随路信令（CAS:Channel Associated Signaling）：信令和话音在同一条话路中传送的信令方式。目前我国采用的随路信令称为中国1号信令系统。 


公共信道信令（CCS:Common Channel Signaling）：以时分方式在一条高速数据链路上传送一群话路的信令的信令方式。通常用于局间。目前我国采用的公共信道信令就是中国7号信令。

中国1号信令：为随路信令。为30/32时隙2048K局间中继传输方式，Timeslot 16被用来传递其话音通道的信令，记发器信令为MFC（多频互控，即用六个频率中的两个组合，成一组编码，共15种前向信令，用四个频率中的两个组合，成一组编码，共6种后向信令，前向是指主叫向被叫传送，后向是指被叫向主叫传送。），线路信令a,b,c,d为xx11。R2信令与中国1号信令的区别在于R2信令的记发器信令为DTMF（双音多频），线路信令a,b,c,d为xx01。

7号信令：SS7是一种公共信道信令。是将呼叫控制信息和其他业&lt;img src =&quot;http://blog.csdn.net/vieri_ch/aggbug/1519541.aspx&quot; width = &quot;1&quot; height = &quot;1&quot; /&gt;</description><pubDate>Sat, 03 Mar 2007 02:50:00 +0800</pubDate><author>vieri_ch</author><comments>http://blog.csdn.net/vieri_ch/archive/2007/03/02/1519541.aspx#Feedback</comments><guid isPermaLink="false">http://blog.csdn.net/vieri_ch/archive/2007/03/02/1519541.aspx</guid><dc:creator>vieri_ch</dc:creator></item><item><title>BSTR详解五 - BSTR与其它字符串类型转换</title><link>http://blog.csdn.net/vieri_ch/archive/2007/02/07/1504054.aspx</link><wfw:comment>http://blog.csdn.net/vieri_ch/comments/1504054.aspx</wfw:comment><slash:comments>0</slash:comments><wfw:commentRss>http://blog.csdn.net/vieri_ch/comments/commentRss/1504054.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1504054</trackback:ping><description>转自http://blog.csdn.net/pkrobbie/
1         类型转换
常用字符串件的类型转换。
 
From To Sample 
字符串常量 BSTR Right:
BSTR bs = ::SysAllocString(_T(&quot;Test string&quot;));
…
::SysFreeString();
Wrong:
BSTR bs = _T(&quot;Test string&quot;); //ERROR 
LPWSTR /
LPCWSTR /
WCHAR* / 
wchar_t BSTR Right:
LPCTSTR sz1 = _T(&quot;Test String&quot;);
BSTR bs = ::SysAllocString(sz1);
…
::SysFreeString();
 
Wrong:
LPTSTR sz1 = _T(&quot;Test String&quot;);
BSTR bs = sz1; //ERROR 
BSTR LPCWSTR /
const WCHAR * /
const wchar_t * Right:
BSTR bs =&lt;img src =&quot;http://blog.csdn.net/vieri_ch/aggbug/1504054.aspx&quot; width = &quot;1&quot; height = &quot;1&quot; /&gt;</description><pubDate>Wed, 07 Feb 2007 18:57:00 +0800</pubDate><author>vieri_ch</author><comments>http://blog.csdn.net/vieri_ch/archive/2007/02/07/1504054.aspx#Feedback</comments><guid isPermaLink="false">http://blog.csdn.net/vieri_ch/archive/2007/02/07/1504054.aspx</guid><dc:creator>vieri_ch</dc:creator></item><item><title>BSTR详解四 - BSTR包容类</title><link>http://blog.csdn.net/vieri_ch/archive/2007/02/07/1504049.aspx</link><wfw:comment>http://blog.csdn.net/vieri_ch/comments/1504049.aspx</wfw:comment><slash:comments>0</slash:comments><wfw:commentRss>http://blog.csdn.net/vieri_ch/comments/commentRss/1504049.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1504049</trackback:ping><description>转自http://blog.csdn.net/pkrobbie/
1.1      Programming with CComBSTR
1.1.1      概述
CComBSTR是ATL提供的BSTR包装类，是VC 6中提供的最完善的BSTR wrapper。就像MFC CString提供了对TCHAR的封装，CComBSTR提供了对BSTR的封装。Table 1 CComBSTR Methods列出了CComBSTR的主要方法。
 
Table 1CComBSTR Methods
       
CComBSTR Method Description 
CComBSTR 多个版本的构造函数用来创建新的BSTR。可以使用的参数包括LPCOLESTR, LPCSTR, CComBSTR。 
~CComBSTR, Empty  释放内部封装的BSTR. 
Attach, Detach, Copy Attach把一个已经存在BSTR加入类中。Detach把劣种的BSTR剥离，以便在超出作用域的时候，析构函数不会释放BSTR。Detach用于把CComBSTR 赋给[ou&lt;img src =&quot;http://blog.csdn.net/vieri_ch/aggbug/1504049.aspx&quot; width = &quot;1&quot; height = &quot;1&quot; /&gt;</description><pubDate>Wed, 07 Feb 2007 18:55:00 +0800</pubDate><author>vieri_ch</author><comments>http://blog.csdn.net/vieri_ch/archive/2007/02/07/1504049.aspx#Feedback</comments><guid isPermaLink="false">http://blog.csdn.net/vieri_ch/archive/2007/02/07/1504049.aspx</guid><dc:creator>vieri_ch</dc:creator></item><item><title>BSTR详解三 - BSTR使用注意事项</title><link>http://blog.csdn.net/vieri_ch/archive/2007/02/07/1504044.aspx</link><wfw:comment>http://blog.csdn.net/vieri_ch/comments/1504044.aspx</wfw:comment><slash:comments>0</slash:comments><wfw:commentRss>http://blog.csdn.net/vieri_ch/comments/commentRss/1504044.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1504044</trackback:ping><description>转自  http://blog.csdn.net/pkrobbie/
1         How to use BSTR
1.1      BSTR分析
BSTR设计对于C++程序员好坏参半。一方面，BSTR可以被用于大多数需要OLECHAR数组作为参数的函数。另一方面，不能用熟悉的C/C++函数进行对BSTR的分配、释放和处理，例如malloc, free, new, delete, lstrcat, and lstrlen 等函数不能用于处理BSTR。就像对接口指针和类指针的处理不一样，对BSTR的处理和对TCHAR*的处理也不一样。BSTR是一种C语言方式的类型定义方式，这种定义方式提高了BSTR在C++的应用效率，但是也带来了很多的潜在风险，它使程序员失去了利用编译器检查潜在问题的机会。
1.2      BSTR使用基本规则
 
在对BSTR进行读取操作的时候，可以把BSTR看作OLECHAR数组。BSTR可以用于const wchar_t*(LPCTSTR/ LPCWSTR/ cosnt TCHAR*/ cosnt WCHAR* in Unicode proje&lt;img src =&quot;http://blog.csdn.net/vieri_ch/aggbug/1504044.aspx&quot; width = &quot;1&quot; height = &quot;1&quot; /&gt;</description><pubDate>Wed, 07 Feb 2007 18:50:00 +0800</pubDate><author>vieri_ch</author><comments>http://blog.csdn.net/vieri_ch/archive/2007/02/07/1504044.aspx#Feedback</comments><guid isPermaLink="false">http://blog.csdn.net/vieri_ch/archive/2007/02/07/1504044.aspx</guid><dc:creator>vieri_ch</dc:creator></item><item><title>BSTR详解二 - 使用时机</title><link>http://blog.csdn.net/vieri_ch/archive/2007/02/07/1504041.aspx</link><wfw:comment>http://blog.csdn.net/vieri_ch/comments/1504041.aspx</wfw:comment><slash:comments>0</slash:comments><wfw:commentRss>http://blog.csdn.net/vieri_ch/comments/commentRss/1504041.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1504041</trackback:ping><description>转自http://blog.csdn.net/pkrobbie/
3         When to use BSTR
只有在你不得不用的时候。
 
使用BSTR一般有以下几种情况：
COM interface接口定义，并且不希望额外提供custom marshaling库（MDIL生成或开发人员自己订制），必须使用BSTR传递字符串。使用C/C++类型的字符串在COM DLL传递字符串，表面上可以使用，但违背了COM的基本规则，并且给以后的扩展留下了隐患。例如，把一个In-process COM Object(简单说COM DLL)改成out-of-process object（COM EXE）。理论上，客户端的代码应该不做任何改变。但如果是用了C/C++字符串，又希望只使用系统的automation mashaller（Oleaut32.dll），就会出错。
如果可以提供custom marshaling，也推荐使用BSTR。 
客户要求接口必须使用BSTR，和客户讨论后，不能修改。 
使用的外部库的接口使用BSTR
 
不使用的情况：
不推荐在IDL结构体中&lt;img src =&quot;http://blog.csdn.net/vieri_ch/aggbug/1504041.aspx&quot; width = &quot;1&quot; height = &quot;1&quot; /&gt;</description><pubDate>Wed, 07 Feb 2007 18:48:00 +0800</pubDate><author>vieri_ch</author><comments>http://blog.csdn.net/vieri_ch/archive/2007/02/07/1504041.aspx#Feedback</comments><guid isPermaLink="false">http://blog.csdn.net/vieri_ch/archive/2007/02/07/1504041.aspx</guid><dc:creator>vieri_ch</dc:creator></item><item><title>BSTR详解一 - BSTR简介和内部结构</title><link>http://blog.csdn.net/vieri_ch/archive/2007/02/07/1504038.aspx</link><wfw:comment>http://blog.csdn.net/vieri_ch/comments/1504038.aspx</wfw:comment><slash:comments>3</slash:comments><wfw:commentRss>http://blog.csdn.net/vieri_ch/comments/commentRss/1504038.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1504038</trackback:ping><description>转自http://blog.csdn.net/pkrobbie/
1         Why need BSTR
COM是一种跨编程语言的平台，需要提供语言无关的数据类型。多数编程语言有自己的字符串表示。
C++ 字符串是以0结束的ASCII或Unicode字符数组 
Visual Basic字符串是一个ASCII字符数组加上表示长度的前缀。 
Java字符串是以0结束的Unicode字符数组。
需要定义一种通用的字符串类型，可以很容易的匹配到不同编程语言。在C++中，就是BSTR。
2         What is BSTR
2.1      BSTR 简介
&quot;Basic STRing&quot;的简称，微软在COM/OLE中定义的标准字符串数据类型。对于C++，Windows头文件wtypes.h中定义如下：
typedef wchar_t WCHAR;
typedef WCHAR OLECHAR;
typedef OLECHAR __RPC_FAR *BSTR;;
2.2      BSTR实现
在COM中，字符用16-bit OLECHAR表示，这样使COM&lt;img src =&quot;http://blog.csdn.net/vieri_ch/aggbug/1504038.aspx&quot; width = &quot;1&quot; height = &quot;1&quot; /&gt;</description><pubDate>Wed, 07 Feb 2007 18:46:00 +0800</pubDate><author>vieri_ch</author><comments>http://blog.csdn.net/vieri_ch/archive/2007/02/07/1504038.aspx#Feedback</comments><guid isPermaLink="false">http://blog.csdn.net/vieri_ch/archive/2007/02/07/1504038.aspx</guid><dc:creator>vieri_ch</dc:creator></item><item><title>请不要做浮躁的嵌入式系统工程师</title><link>http://blog.csdn.net/vieri_ch/archive/2007/01/16/1484494.aspx</link><wfw:comment>http://blog.csdn.net/vieri_ch/comments/1484494.aspx</wfw:comment><slash:comments>0</slash:comments><wfw:commentRss>http://blog.csdn.net/vieri_ch/comments/commentRss/1484494.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1484494</trackback:ping><description>1. 不要看到别人的回复，第一句话就说：给个代码吧！你应该想想为什么。当你自己想出来再参考别人的提示，你就知道自己和别人思路的差异。 
Give me five ,don't code.

2. 初学者请不要看太多的书那会误人子弟的。先找一本好书系统的学习。很多人用了很久都是只对部分功能熟悉而已，不系统还是不够的。 
乱花渐欲迷人眼
3. 看帮助。不要因为很难，而自己又是初学者所以就不看；帮助永远是最好的参考手册，虽然帮助的文字有时候很难看懂，或不够直观。 
help me ,see help
4. 不要被一些专用词汇所迷惑；最根本的是先了解最基础知识。 
要有抓住本质的欲望，而不是沉迷于词汇
5. 不要放过任何一个看上去很简单的小问题--他们往往并不那么简单，或者可以引伸出很多知识点；不会举一反三你就永远学不会。 
触类旁通，关联思维
6. 知道一点东西，并不能说明你会用，会用是需要实践经验和时间积累的。 
to do something
7. 入门并不难，难的是长期坚持实践和不遗余力的学习和实践。 
Unremitting and devotion
8&lt;img src =&quot;http://blog.csdn.net/vieri_ch/aggbug/1484494.aspx&quot; width = &quot;1&quot; height = &quot;1&quot; /&gt;</description><pubDate>Tue, 16 Jan 2007 21:57:00 +0800</pubDate><author>vieri_ch</author><comments>http://blog.csdn.net/vieri_ch/archive/2007/01/16/1484494.aspx#Feedback</comments><guid isPermaLink="false">http://blog.csdn.net/vieri_ch/archive/2007/01/16/1484494.aspx</guid><dc:creator>vieri_ch</dc:creator></item><item><title>使用画刷在背景中平铺位图</title><link>http://blog.csdn.net/vieri_ch/archive/2006/12/19/1448719.aspx</link><wfw:comment>http://blog.csdn.net/vieri_ch/comments/1448719.aspx</wfw:comment><slash:comments>0</slash:comments><wfw:commentRss>http://blog.csdn.net/vieri_ch/comments/commentRss/1448719.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1448719</trackback:ping><description>1.重载OnEraseBkgnd
修改return CEditView::OnEraseBkgnd(pDC);为return true;

2.从文件中加载位图 

BOOL CbackbrushView::OnEraseBkgnd(CDC* pDC)
{
   HBITMAP bitmap=(HBITMAP)::LoadImage(AfxGetInstanceHandle(),&quot;c:\touxiang.bmp&quot;,IMAGE_BITMAP ,0,0,LR_DEFAULTSIZE | LR_LOADFROMFILE);
   CBrush brush;
   //创建Pattern画刷
  brush.CreatePatternBrush(CBitmap::FromHandle(bitmap));
   CBrush* pOldBrush;
   //把画刷选入pDC上下文，并保存原先的画刷
  pOldBrush = (CBrush*)pDC-&gt;Selec....&lt;img src =&quot;http://blog.csdn.net/vieri_ch/aggbug/1448719.aspx&quot; width = &quot;1&quot; height = &quot;1&quot; /&gt;</description><pubDate>Tue, 19 Dec 2006 19:52:00 +0800</pubDate><author>vieri_ch</author><comments>http://blog.csdn.net/vieri_ch/archive/2006/12/19/1448719.aspx#Feedback</comments><guid isPermaLink="false">http://blog.csdn.net/vieri_ch/archive/2006/12/19/1448719.aspx</guid><dc:creator>vieri_ch</dc:creator></item></channel></rss>