Diff for /parser3/src/classes/xnode.C between versions 1.28 and 1.31

version 1.28, 2002/01/21 13:04:02 version 1.31, 2002/01/24 13:57:19
Line 27  extern "C" { Line 27  extern "C" {
   
 class xmlXPathObject_auto_ptr {  class xmlXPathObject_auto_ptr {
 public:  public:
         explicit xmlXPathObject_auto_ptr(xmlXPathObject *_P = 0)           explicit xmlXPathObject_auto_ptr(xmlXPathObject *_APtr = 0) 
                 : _Owns(_P != 0), _Ptr(_P) {}                  : _Owns(_APtr != 0), _Ptr(_APtr) {}
         xmlXPathObject_auto_ptr(const xmlXPathObject_auto_ptr& _Y)           xmlXPathObject_auto_ptr(const xmlXPathObject_auto_ptr& _Y) 
                 : _Owns(_Y._Owns), _Ptr(_Y.release()) {}                  : _Owns(_Y._Owns), _Ptr(_Y.release()) {}
         xmlXPathObject_auto_ptr& operator=(const xmlXPathObject_auto_ptr& _Y)           xmlXPathObject_auto_ptr& operator=(const xmlXPathObject_auto_ptr& _Y) 
Line 60  private: Line 60  private:
   
 class xmlXPathContext_auto_ptr {  class xmlXPathContext_auto_ptr {
 public:  public:
         explicit xmlXPathContext_auto_ptr(xmlXPathContext *_P = 0)           explicit xmlXPathContext_auto_ptr(xmlXPathContext *_APtr = 0) 
                 : _Owns(_P != 0), _Ptr(_P) {}                  : _Owns(_APtr != 0), _Ptr(_APtr) {}
         xmlXPathContext_auto_ptr(const xmlXPathContext_auto_ptr& _Y)           xmlXPathContext_auto_ptr(const xmlXPathContext_auto_ptr& _Y) 
                 : _Owns(_Y._Owns), _Ptr(_Y.release()) {}                  : _Owns(_Y._Owns), _Ptr(_Y.release()) {}
         xmlXPathContext_auto_ptr& operator=(const xmlXPathContext_auto_ptr& _Y)           xmlXPathContext_auto_ptr& operator=(const xmlXPathContext_auto_ptr& _Y) 
Line 425  static void selectNodesHandler(Pool& poo Line 425  static void selectNodesHandler(Pool& poo
                                                           const String& expression,                                                            const String& expression,
                                                           xmlXPathObject_auto_ptr res,                                                            xmlXPathObject_auto_ptr res,
                                                           Value *& result) {                                                            Value *& result) {
           VHash *vhash=new(pool) VHash(pool);  result=vhash;
         switch(res->type) {          switch(res->type) {
         case XPATH_UNDEFINED:           case XPATH_UNDEFINED: 
                 break;                  break;
         case XPATH_NODESET:          case XPATH_NODESET:
                 if(int size=res->nodesetval->nodeNr) {                  if(int size=res->nodesetval->nodeNr) {
                         VHash *vhash=new(pool) VHash(pool);  
                         Hash& hash=vhash->hash(0);                          Hash& hash=vhash->hash(0);
                         for(int i=0; i<size; i++) {                          for(int i=0; i<size; i++) {
                                 String& skey=*new(pool) String(pool);                                  String& skey=*new(pool) String(pool);
Line 441  static void selectNodesHandler(Pool& poo Line 441  static void selectNodesHandler(Pool& poo
                                 }                                  }
   
                                 hash.put(skey, new(pool) VXnode(pool,                                   hash.put(skey, new(pool) VXnode(pool, 
                                         gdome_xml_n_mkref(res->nodesetval->nodeTab[0])));                                          gdome_xml_n_mkref(res->nodesetval->nodeTab[i])));
                         }                          }
                         result=vhash;  
                 }                  }
                 break;                  break;
         default:           default: 

Removed from v.1.28  
changed lines
  Added in v.1.31


E-mail: