VBlob values
Ernesto Giannotta
ernestogiannotta at tiscalinet.it
Sun Jun 13 03:38:21 CDT 2010
Hi Ruslan,
VBlob has methods:
-(NSData*) readRawData;
-(void) writeRawData:(NSData*) inNewValue;
that work pretty fine.
However calling super methods:
- (id)value;
- (void)setValue:(id)inValue;
I don't get the same expected results
(VBlob:value will return 0 for null blobs and 1 for not null ones)
why VBlob:value behaves different from other fields?
I guess this being a detail implementation but shouldn't it be transparently handled for us?
I'd like to have VBlob methods consistent with other VFields like:
-(NSData*)dataValue;
-(void)setDataValue:(NSData*) inNewValue;
(no big deal, just a naming convention change)
and super:value return the expected object...
Well, I understand this will likely break the OOP logic purity
forcing some "if" check on your side to handle this special case
But as things stand now this sanity check is just deferred on our side
that in theory should know nothing about internal implementation details
(like the fact that I imagine you mark with 0 a null blob and 1 a not null one)
What do you think?
Cool Runnings,
Erne.
More information about the Valentina
mailing list