You are here

public function csl_locale::__wakeup in Bibliography Module 7

Same name and namespace in other branches
  1. 6.2 modules/CiteProc/CSL.inc \csl_locale::__wakeup()
  2. 7.2 modules/CiteProc/CSL.inc \csl_locale::__wakeup()

SimpleXML objects cannot be serialized, so when un-serializing them, they must rebuild from the serialized XML string.

File

modules/CiteProc/CSL.inc, line 2080
CiteProc-PHP.

Class

csl_locale

Code

public function __wakeup() {
  $this->style_locale = !empty($this->style_locale_xmlstring) ? new SimpleXMLElement($this->style_locale_xmlstring) : NULL;
  $this->locale = !empty($this->locale_xmlstring) ? new SimpleXMLElement($this->locale_xmlstring) : NULL;
  if ($this->locale) {
    $this->locale
      ->registerXPathNamespace('cs', 'http://purl.org/net/xbiblio/csl');
  }
}