锘??xml version="1.0" encoding="utf-8" standalone="yes"?>亚洲综合在线一区,在线播放一区二区三区,亚洲欧美另类人妖http://www.aygfsteel.com/nobody_am/category/3085.html<br> Toooooo many Thingzh-cnWed, 28 Feb 2007 08:18:28 GMTWed, 28 Feb 2007 08:18:28 GMT60CSocket鍘熷鐨凷end鍜孯eceive璋冪敤鏂規硶http://www.aygfsteel.com/nobody_am/articles/23428.htmlMingIsMeMingIsMeMon, 12 Dec 2005 03:19:00 GMThttp://www.aygfsteel.com/nobody_am/articles/23428.htmlhttp://www.aygfsteel.com/nobody_am/comments/23428.htmlhttp://www.aygfsteel.com/nobody_am/articles/23428.html#Feedback0http://www.aygfsteel.com/nobody_am/comments/commentRss/23428.htmlhttp://www.aygfsteel.com/nobody_am/services/trackbacks/23428.html //Receive============================
 CString tst;
 char * pp= tst.GetBuffer(1000);  
 int len=0;
 pp[0] = 0;
 len = pSocket->Receive(pp, 999);
 pp[len]=0;
 tst.ReleaseBuffer(); 
 m_strDisplayMsg=tst;

 //Send===============================
 CString tmp  = "Hello";
 int len = tmp.GetLength();
 char *pp = tmp.GetBuffer(len+2);
 Send(pp,len);
 tmp.ReleaseBuffer();



MingIsMe 2005-12-12 11:19 鍙戣〃璇勮
]]>
鏍規嵁鍒嗛殧絎﹁В鏋愬瓧絎︿覆http://www.aygfsteel.com/nobody_am/articles/11528.htmlMingIsMeMingIsMeTue, 30 Aug 2005 01:52:00 GMThttp://www.aygfsteel.com/nobody_am/articles/11528.htmlhttp://www.aygfsteel.com/nobody_am/comments/11528.htmlhttp://www.aygfsteel.com/nobody_am/articles/11528.html#Feedback0http://www.aygfsteel.com/nobody_am/comments/commentRss/11528.htmlhttp://www.aygfsteel.com/nobody_am/services/trackbacks/11528.html
// StringTokenizer.h: interface for the CStringTokenizer class.
//
//////////////////////////////////////////////////////////////////////

#if !defined(AFX_STRINGTOKENIZER_H__68F125DE_4839_49DD_8116_D7BC0BAF3853__INCLUDED_)
#define AFX_STRINGTOKENIZER_H__68F125DE_4839_49DD_8116_D7BC0BAF3853__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include 
<afxwin.h>
class CStringTokenizer 
{
public:
    CString NextToken();
    BOOL HasMoreTokens();
    CStringTokenizer(CString s,CString c);
    
virtual ~CStringTokenizer();

private:
    CStringList m_strList;
  POSITION m_pos;
}
;

#endif // !defined(AFX_STRINGTOKENIZER_H__68F125DE_4839_49DD_8116_D7BC0BAF3853__INCLUDED_)

Part 2 Cpp鏂囦歡
// StringTokenizer.cpp: implementation of the CStringTokenizer class.
//
//////////////////////////////////////////////////////////////////////

#include 
"StringTokenizer.h"

//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////

CStringTokenizer::CStringTokenizer(CString s,CString c)

  
int start=0;
  
int end=-1;
  
while(end<=s.GetLength())
  
{
    start
=end+1;
    end
=s.Find(c,start);
    
if(end==-1)
    
break; }
    m_strList.AddTail(s.Mid(start,end
-start));
  }

  m_pos
=m_strList.GetHeadPosition();
}


CStringTokenizer::
~CStringTokenizer()
{

}


BOOL CStringTokenizer::HasMoreTokens()
{
  
return m_pos!=NULL;
}


CString CStringTokenizer::NextToken()
{
  ASSERT(m_pos
!=NULL);
  
return m_strList.GetNext(m_pos);
}



MingIsMe 2005-08-30 09:52 鍙戣〃璇勮
]]>
主站蜘蛛池模板: 鲁山县| 潮安县| 合阳县| 阿拉善右旗| 沙湾县| 平原县| 遵化市| 平远县| 鲜城| 柳州市| 称多县| 清水河县| 天等县| 玉林市| 门头沟区| 门源| 乌鲁木齐县| 阿拉善盟| 巨鹿县| 武强县| 定边县| 封丘县| 灌南县| 南开区| 景东| 长沙县| 虎林市| 岗巴县| 奉节县| 灵璧县| 芒康县| 安庆市| 米林县| 满城县| 永丰县| 巴南区| 若尔盖县| 嘉定区| 峡江县| 禹城市| 汝阳县|