On 07/09/11 04:10, Mauricio Etchevest wrote: > Hi, thanks for the answers. > > The thing I want to do is perform some semantic refactorings. > So I need to know wich are all the special annotations that SMW use. > Your recomendation is to look into the user manual and make a > compilation of all of them ? Maybe they belong to a category so it´s so > much easy to look for.. > > Then I need to modify and update some annotations, so this may be done > by editing the wiki-text in the page where it´s belonge?
I still do not quite understand "I need to know wich are all the special annotations that SMW use." Do you mean that you need to know all the *names of special properties* that SMW uses? Or are you interested in their *stored values* for a particular page? A "special property" in SMW is "special" because it has a predefined datatype and an internal ID. Other than this, the special properties are just like normal properties. In particular, there is no fixed set of special properties. Extensions can add their own properties to store special information that they need. There is a list of currently registered special properties together with their type, but SMW does not currently have a method to retrieve this list (it was not needed so far). You can see the default special properties in ./includes/dataitems/SMW_DI_Property.php in method initPropertyRegistration() where this list is initialised. Also note that special properties have an ID and a datatype, but they may or may not have a user-readable label that can be used in the wiki (in queries or annotations). Special properties that are not labelled are used internally to store data that is not directly relevant to the user. So you cannot find all special properties in the user manual: some of them are not visible to users at all. The user labels, if any, are defined in the SMW_Language.php files in ./languages/ and of course they are different for each language. You can use SMWDIProperty::findPropertyLabel() to get the label of a special property in the current wiki language. Markus > On Tue, Sep 6, 2011 at 11:54 AM, Markus Krötzsch > <mar...@semantic-mediawiki.org <mailto:mar...@semantic-mediawiki.org>> > wrote: > > On 06/09/11 15:16, Yaron Koren wrote: > > Hi Markus, > > It's not quite true that SMW "only stores data that is actually > found on > a page" - there's also metadata that it can store, like the current > "Modification date" special property. I guessed, when I read > Mauricio's > email, that that's what he was talking about, though I could be > wrong. > > > Right, this is a special case that I did not think about. In this > case, it is actually only the modification date that is stored by > SMW. It turned out that it is not so easy to have a simple, unified > place to get and record such MediaWiki-based data in SMW, hence it > was only done for the modification date yet (and this is already > covered in two places so as to not be deleted accidentally in update > operations). Other data of this type would be handled similarly, but > it depends on the data where exactly is the best place to get it > from MW. > > Markus > > On Tue, Sep 6, 2011 at 9:49 AM, Markus Krötzsch > <mar...@semantic-mediawiki.org > <mailto:mar...@semantic-mediawiki.org> <mailto:markus@semantic- > mediawiki.org <mailto:mar...@semantic-mediawiki.org>>> > > wrote: > > On 05/09/11 15:34, Mauricio Etchevest wrote: > > Hi, > > > > I'm working on an new extension for SMW. > > Great. > > > > > There're two things that don't work out: > > > > My extension has to generate new semantic annotations without any > user > > input, > > Anybody could tell me how to start ? Any recommendations on > what to > > read or which classes are important to do that? > > You might want to look at the SMWWriter extension for SMW > that addresses > part of this task. However, SMW is not a general purpose > store for > annotations and it only stores data that is actually found > on a page (in > wikitext). So adding annotations can only be done by writing the > wiki text. > > > > > Anyone could tell my where to find a list of all semantic > annotations > > that users can use ? I have the feeling that I'm missing > something here, > > It seems yo me that there might be more semantic annotations > than the > > ones that appear in the user manual. > > Users can use any annotation they like. With this I mean: > they can use > properties with arbitrary names and they can assign > arbitrary values to > these properties for every page. The only restriction is > that the value > must make sense in the datatype of the property (for > example, a property > of type Number can only have values that are numbers). > > There are also a few special annotations that SMW looks for > to figure > out certain user settings. For example, the datatype of a > property is > set as a value for the property "has type" as in [[has > type::Number]]. > These special things are what is documented in the user > manual. All > other annotations do not have a special meaning for SMW > (they are "just" > data). > > Regards > > Markus > > > > > > ------------------------------ > ------------------------------ ------------------ > > Special Offer -- Download ArcSight Logger for FREE! > > Finally, a world-class log management solution at an even better > > price-free! And you'll get a free "Love Thy Logs" t-shirt > when you > > download Logger. Secure your free ArcSight Logger TODAY! > > http://p.sf.net/sfu/ arcsisghtdev2dev > <http://p.sf.net/sfu/arcsisghtdev2dev> > > > > > > > > ______________________________ _________________ > > Semediawiki-devel mailing list > > Semediawiki-devel@lists. sourceforge.net > <mailto:Semediawiki-devel@lists.sourceforge.net> > <mailto:Semediawiki-devel@ lists.sourceforge.net > <mailto:Semediawiki-devel@lists.sourceforge.net>> > > > https://lists.sourceforge.net/ lists/listinfo/semediawiki- > devel > <https://lists.sourceforge.net/lists/listinfo/semediawiki-devel> > > > ------------------------------ > ------------------------------ ------------------ > Special Offer -- Download ArcSight Logger for FREE! > Finally, a world-class log management solution at an even better > price-free! And you'll get a free "Love Thy Logs" t-shirt > when you > download Logger. Secure your free ArcSight Logger TODAY! > http://p.sf.net/sfu/ arcsisghtdev2dev > <http://p.sf.net/sfu/arcsisghtdev2dev> > ______________________________ _________________ > Semediawiki-devel mailing list > Semediawiki-devel@lists. sourceforge.net > <mailto:Semediawiki-devel@lists.sourceforge.net> > <mailto:Semediawiki-devel@ lists.sourceforge.net > <mailto:Semediawiki-devel@lists.sourceforge.net>> > > https://lists.sourceforge.net/ lists/listinfo/semediawiki- devel > <https://lists.sourceforge.net/lists/listinfo/semediawiki-devel> > > > > > -- > WikiWorks · MediaWiki Consulting · http://wikiworks.com > > > ------------------------------------------------------------------------------ Using storage to extend the benefits of virtualization and iSCSI Virtualization increases hardware utilization and delivers a new level of agility. Learn what those decisions are and how to modernize your storage and backup environments for virtualization. http://www.accelacomm.com/jaw/sfnl/114/51434361/ _______________________________________________ Semediawiki-devel mailing list Semediawiki-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/semediawiki-devel