<div class="gmail_quote"><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<br>
FINALLY SOMEONE LOOKS AT THIS STUFF BESIDES ME!!!!!!!!!!!!!!!!<br>
THANK YOU! :)<br>
<br></blockquote><div><br>:-)<br></div><div> </div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div class="im">
On 05/07/2010 01:15 PM, Vishesh Handa wrote:<br>
> 1. The *Nepomuk::ResourceData::hasProperty( const QUrl& uri )* function<br>
> currently uses the MAINMODEL to answer. It think it should use the<br>
> cache, as it would be faster. The function *hasProperty( const QUrl& p,<br>
> const Variant& v ) *also uses the cache. A patch has been provided.<br>
<br>
</div>yes, please commit.<br>
<div class="im"><br></div></blockquote><div><br>Done!<br> </div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div class="im">
> 2. The *Nepomuk::ResourceData::removeProperty( const QUrl& uri )*<br>
> function doesn't update the cache. The setProperty function does. It<br>
> should be symmetrical. I think.<br>
<br>
</div>also correct.<br>
<br>
Can you backport this one?<br>
<br></blockquote><div><br>Committed and backported. <br></div><div class="im"> <br>
<br>
</div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">You are correct. But as you said the method is not used anyway, so we<br>
better remove it. right?<br></blockquote><div><br>I was going through the code again and the documentation clearly mentions that this function is meant for properties whose cardinality is one. (I missed this!)<br> <br>
/**<br> * Update a property. This means an existing property is replaced if it differs from<br> * the provided value. Otherwise nothing is done.<br> *<br> * This method assumes that the cardinality or property is 1.<br>
*/<br><br>So, it's doing exactly what it should. There is no reason to remove it. We could put a warning if the cardinality is greater than 1 or modify it so that it doesn't do anything if the cardinality > 1. I'll write a patch tomorrow.<br>
<br>- Vishesh Handa
<br></div></div>