quentin.mathe@gmail.com
)Copyright: (C) 2013 Quentin Mathe
- Declared in:
- ETMutableObjectViewpoint.h
- Conforms to:
- ETPropertyViewpoint
@group Viewpoints @abstract A proxy giving access to a model property as a mutable object.
ETMutableObjectViewpoint turns an attribute or to-one relationship property belonging to a represented object, into a mutable object proxy that updates the model property with a new immutable object in reaction to -setValue:forProperty: .
ETMutableObjectViewpoint doesn't work as a mutable collection proxy for a to-many relationship property, you must use ETCollectionViewpoint instead.
Using a mutable object as ETMutableObjectViewpoint value doesn't bring a lot of benefits, but is well supported and works transparently.
For supporting editing a mutable object class, ETMutableObjectViewpoint must be subclassed. For example, for editing NSSortDescriptor, you must implement a new subclass such as ETMutableSortDescriptorViewpoint (this one is provided by EtoileUI though).
This viewpoint uses Key-Value-Observing to detect any property changes on the represented object.
@taskunit Initialization
Returns a value bound to a property of the object -value . This method accesses properties of the represented property.
@taskunit Property Value Coding
Returns a value bound to a property of the object -value . This method accesses properties of the represented property.