Michiel Meeuwissen wrote:
Nico Klasens wrote:

I have only one question about this. Why are the fields
object.owner and insrel.dir persistent and not system?

I am trying to make a distinction in my code which fields can be
written by a user and which ones not. I didn't have problems in
previous releases of mmbase, because I excluded all the object and
insrel fields, but now with the new datatype features this is not
enough.

org.mmbase.bridge.BridgeException: You cannot change the field
lastmodifier at org.mmbase.datatypes.processors.LastModifier.process(LastModifier.java:35) at org.mmbase.datatypes.BasicDataType.process(BasicDataType.java:476) at org.mmbase.bridge.implementation.BasicNode.setStringValue(BasicNode.java:519)


I thought to do it by checking if the field is system managed, but
then the above mentioned fields are an exception on that rule. Can
I just change these field definitions to state="system"?



I normally check in 'system', indeed to check of a field is user-modifiable.

But why couldn't owner and dir be changed?

Anyhow, I thing I agree that even if they could be changeable, you shouldn't want that, so perhaps state="system" would work just fine.
Perhaps we can simply try it out for a while?

System maintained doesn't mean the user can't change it. It does only mean that the system will put values in it. An user should know what it is doing when it is changing the field.

Do I need a vote for chaging this?

Nico

_______________________________________________
Developers mailing list
[email protected]
http://lists.mmbase.org/mailman/listinfo/developers

Reply via email to