Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

linux tinyxml±éÀú

·½·¨Ò»¡¢
bool ReadElemnt(string& szFileName)
{
 TiXmlDocument myDocument(szFileName);   
  bool loadOkay = myDocument.LoadFile();
  if(loadOkay == false)
   return false;
 TiXmlElement *rootElement = myDocument.RootElement();
 if(rootElement == NULL)
  return false;
 
 TiXmlElement *pItemElement = rootElement->FirstChildElement();
 TiXmlNode *pNextchild = pItemElement->ToElement();
 while(pNextchild)
 {
  pItemElement = pNextchild->ToElement();  
  
    TiXmlElement *NameElement = pItemElement->FirstChildElement();
    TiXmlElement *AgeElement = NameElement->NextSiblingElement();
    TiXmlAttribute *IDAttribute = pItemElement->FirstAttribute();       
    //Êä³öµÚÒ»¸öPersonµÄnameÄÚÈÝ£¬¼´ÖÜÐÇÐÇ£»ageÄÚÈÝ£¬¼´20£»IDÊôÐÔ£¬¼´1¡£     
  cout << NameElement->FirstChild()->Value() << "<br>";         
    cout << AgeElement->FirstChild()->Value() << "<br>";
    cout << IDAttribute->Value() << "<br>\n";
    
    pNextchild = pNextchild->NextSibling();
 }
 
 return true;
}
·½·¨¶þ¡¢
void ParaseUpdateXml(TiXmlNode* pParent)
{
  if(pParent == NULL)
  return;        
  TiXmlNode* pChild = pParent->FirstChild();    
  while(pChild)
  {          
    cout << pChild->Value() << "<br>";
    int t = pChild->Type();
    if( t == TiXmlNode::ELEMENT)


Ïà¹ØÎĵµ£º

Linux Çý¶¯ hello

#include <linux/module.h>
MODULE_LICENSE("GPL");
static void hello_init(void);
static void hello_exit(void);
static void hello_init(void)
{
     printk("init");
}
static void hello_exit(void)
{
    printk("exit");
}
.
module_init(hello_init);
m ......

LinuxÏÂÍê³ÉµÄÒ»¸ö×÷Òµ³ÌÐò

Îĵµ´´½¨ÈÕÆÚ£º2010-02-19
    01    // P174: 2.±à³ÌÌâ (13)²»ÀûÓÃstrcmpº¯Êý£¬×Ô¼º±à³ÌʵÏÖÁ½¸öÈÎÒâ×Ö·û´®µÄ±È½Ï¡£
    02   
    03    // The beginning of C program: test06-13.c.
    04 &nbs ......

±àÒë linux 2.6.18³ö´í½â¾ö·½·¨

HOSTCC scripts/mod/sumversion.o
scripts/mod/sumversion.c: In function ‘get_src_version’:
scripts/mod/sumversion.c:384: error: ‘PATH_MAX’ undeclared (first use in
this function)
scripts/mod/sumversion.c:384: error: (Each undeclared identifier is reported
only once
script ......

ʵÏÖLinuxË«»úÎļþͬ²½rsync

rsync ÓÐʲôͻ³öÓŵãÄØ£¿Ê×ÏÈ£¬Ëü±»Éè¼Æ³ÉÖ»´«ËÍÎļþµÄ²»Í¬²¿·Ö£¬¶ø·Ç´«ËÍÕû¸öÎļþ£¬ÒÔ¼ÓËÙÎļþ´«Êä¡£±ÈÈ磬ÎÒÕýÔÚд×÷±¾ÎÄ£¬ÄÇÎҾͿÉÒÔÏÖÔÚʹÓÃ
rsync ¸´ÖÆÒ»´Î£¬¶øÖ®ºóÔÙ½øÐÐÒ»´Î´«Êä¡£µÚ¶þ´Î£¨µÚÈý´Î¡¢µÚËÄ´Î……£©¸¸×ÓÎļþµÄʱºò£¬rsync
Ö»´«ËÍÎļþµÄ²»Í¬²¿·Ö¡£Õ⽫¼«´óµØ½Úʡʱ¼ä£¬ÌرðÊÇÔÚÈÕ³£±¸·ÝµÄ¹ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ