Maybe Markus has some hints? :)

// Samuel

On 11/05/2011 05:20 AM, Samuel Lampa wrote:
> In the SMWARC2Store class, that I created (more or less copying the
> JosekiStore class in SparqlExtension), I nowadays get a crash in one of
> the methods, which is calling the getExportData() method on an
> SMWWikiPageValue object, but that method does not exist anymore in the
> SMWWikiPageValue class.
>
> Is there any alternative for grabbing that data, for a given WikiPage/Title?
>
> Attached the relevant function, in SMWARC2Store below, with the relevant
> line ("$exp = $dv->getExportData();") somewhere in the middle:
>
>
> /**
>    * Having a title of a page, what is the URI described by that page?
>    * The result still requires expandURI()
>    * @param string $title
>    * @return string $uri
>    */
> protected function getURI( $title ) {
>       $uri = "";
>       if ( $title instanceof Title ) {
>           $dv = SMWDataValueFactory::newTypeIDValue( '_wpg' );
>           $dv->setTitle( $title );
>           $exp = $dv->getExportData();
>           $uri = $exp->getSubject()->getUri();
>       } else {
>           // There could be other types as well that we do NOT handle here
>       }
>       return $uri; // still requires expandURI()
> }
>
> // Samuel
>


-- 
Samuel Lampa
---------------------------------------
  Bioinformatician @ Uppsala University
    Blog: http://saml.rilspace.org
---------------------------------------

------------------------------------------------------------------------------
RSA(R) Conference 2012
Save $700 by Nov 18
Register now
http://p.sf.net/sfu/rsa-sfdev2dev1
_______________________________________________
Semediawiki-devel mailing list
Semediawiki-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/semediawiki-devel

Reply via email to