Is an NSValueTransform subclass which is a good option for displaying core data properties in displaying UI data:
- A string in the string (0,1,2,3, etc.) such as (pending, complete, frozen, in progress, etc.)
- Like a number string (0 , 1) has an app based image (red 0, if 0, green.png if 1)
Core properties are displayed for two properties, timers and positions:
Instead, I want to display instead the value in core data:
If not to use NSValueTransformer, what is this other way?
I do not want to see the data change permanently, only for the benefit of low data stored in core data and better UI visual items.
I have also tried to modify attr Ibit in managed object class (with KVO notification) with no luck.
Yes, NSValueTransformer
subclasses work fine for this purpose.
You can add read-only properties to your managed object class, and that should also work.
For example:
+ (If you do not, these properties can be added to a range in the controller code. Ansset *) Kunjeepetsfor Valuafingingstatsdisplenam {Returns [nset set with object: @ "status"]; } - (NSString *) status change {NSString * status = self.status; If ([Position is EqualToString: @ "0"]) @ "pending" return; And if ([position is EqualToString: @ "1"]) @ "full" return;
+ keyPathsForValuesAffectingStatusDisplayName
method to know the Kevio and binding when status changes
, then the new Sthitipradrshnnam
See the documentation for Property + keyPathsForValuesAffectingValueForKey:
how it works.
No comments:
Post a Comment