I'm finishing a TDataset descendant and, to conclude it, need help in the following issues (I'm using fpc 1.9.4):
- Currently neither the TField* classes nor the TDataset descendants check the ReadOnly property of the Field, making possible to change field value through SetFieldData. Should descendants do the check? If it's a open issue, i suggest that the check must be done in TField scope since doesn't makes sense call SetFieldData to a ReadOnly Field.
- I noticed that TField can call SetFieldData with Buffer = nil. How Descendant should handle this?. Only one of the descendants check if it's nil.
- TField supports NULL values?. How Tfield handles them?
- In the currently implemented TDataset descendants (fpc 1.9.4), in GetRecord methods, grError is only set when GetMode is gmCurrent. Is it the expected?. If yes, it's possible to remove the DoCheck parameter, letting the caller check the result (GetRecord is called only twice with gmCurrent in dataset.inc), and simplifying the GetRecord implementation. In fact TDataset is checking the result now.
- In TDataset, Append is implemented but InternalAddRecord is not called. Is it deliberated?
- TDataset property RecNo is not mapped to GetRecNo SetRecNo
by the way,
While trying to change Attributes property of a TFieldDef object with include(AFieldDef.Attributes,faReadOnly)
i get the following error: Error: Incompatible types: got "ShortInt" expected "TFieldAttribute"
The compiler is using the sysutils constant instead of TFieldAttributes
Thanks in advance Luiz
_______________________________________________ fpc-devel maillist - [EMAIL PROTECTED] http://lists.freepascal.org/mailman/listinfo/fpc-devel
