Exemplo n.º 1
0
   State &operator= (const State &Value) {

      cache = 0;

      if (Value.context && (Value.context != context)) {

         if (context) { context->unref (); context = 0; }

         context = Value.context;

         if (context) { context->ref (); }
      }

      dataTable.empty ();
      dataTable.copy (Value.dataTable);

      if (Value.stringTable) {

         if (!stringTable) { stringTable = new stringStruct; }
         if (stringTable) { *stringTable = *(Value.stringTable); }
      }
      else if (stringTable) { delete stringTable; stringTable = 0; }

      return *this;
   };
Exemplo n.º 2
0
   ~State () {

      levelTable.clear ();

      if (_handlePtr) { delete _handlePtr; _handlePtr = 0; }
      else {

         Definitions defs (context);
         defs.release_unique_name (Name);
      }

      if (context) { context->unref (); context = 0; }

      if (lib) { delete lib; lib = 0; }
   }
Exemplo n.º 3
0
   ~State () {

      if (defs) { defs->unref (); defs = 0; }
      if (context) { context->unref (); context = 0; }
      log = 0;
   }
Exemplo n.º 4
0
 ~State () { empty (); if (context) { context->unref (); } }