/**
  * @param DOMElement $xml
  */
 public function load_local_objects_domxml($xml)
 {
     $this->xmlroot = $xml;
     $i = 0;
     foreach ($xml->childNodes as $node) {
         if ($node->nodeType != 1) {
             continue;
         }
         $lname = $node->textContent;
         if ($i == 0) {
             if ($lname == 'any') {
                 break;
             }
             if ($lname == 'application-default') {
                 $this->appdef = true;
                 break;
             }
         }
         $f = $this->parentCentralStore->findOrCreate($lname);
         $f->addReference($this);
         $this->all[] = $f;
         $this->add_Obj_inIndex($f, lastIndex($this->all));
         $i++;
     }
     $this->regen_Indexes();
 }
 public function load_from_domxml($xml)
 {
     $this->xmlroot = $xml;
     $this->name = DH::findAttribute('name', $xml);
     if ($this->name === FALSE) {
         derr("name not found\n");
     }
     if ($this->owner->owner->version >= 60) {
         $membersRoot = DH::findFirstElement('members', $this->xmlroot);
         if ($membersRoot === false) {
             derr('unsupported non v6 syntax type ServiceGroup', $this->xmlroot);
         }
         foreach ($membersRoot->childNodes as $node) {
             if ($node->nodeType != 1) {
                 continue;
             }
             $memberName = $node->textContent;
             if (strlen($memberName) < 1) {
                 derr('found a member with empty name !', $node);
             }
             $f = $this->owner->findOrCreate($memberName, $this, true);
             $this->members[] = $f;
         }
     } else {
         foreach ($xml->childNodes as $node) {
             if ($node->nodeType != 1) {
                 continue;
             }
             $memberName = $node->textContent;
             if (strlen($memberName) < 1) {
                 derr('found a member with empty name !', $node);
             }
             $f = $this->owner->findOrCreate($memberName, $this, true);
             $this->members[] = $f;
         }
     }
 }