Manual talk:ORMTable
Latest comment: 12 years ago by Jeroen De Dauw in topic Please slap me
setField/setFields
edit- Shoudn't setField simply be dropped in favour of setFields()? --siebrand 19:45, 9 February 2012 (UTC)
- Shoudn't getField simply be dropped in favour of getFields()? --siebrand 19:46, 9 February 2012 (UTC)
These are not equivalent.
- setField sets a field, while setFields allows you to specify if you want to override the fields if they are already set or not. Merging these would also result into having to do
setFields( array( 'foo' => 'bar' ) )
instead ofsetField( 'foo', 'bar' )
- getField will attempt to get the field with the name you provided and complain if it is not set. getFields does not take any argument and simply returns all set fields.
-- Jeroen De Dauw 02:26, 10 February 2012 (UTC)
Apparently I misdocumented these functions a little - your remark makes perfect sense for what I originally wrote. It's corrected now :)
-- Jeroen De Dauw 02:34, 10 February 2012 (UTC)
- Thanks. --siebrand 08:24, 12 February 2012 (UTC)
Please slap me
editIf I did not update this completely by 2012-7-22 :) --Jeroen De Dauw (talk) 03:08, 16 July 2012 (UTC)
- Ah, just in time :D --Jeroen De Dauw (talk) 19:17, 21 July 2012 (UTC)
Namespace
editShouldn't this be in the manual namespace as opposed to the help namespace? Bawolff (talk) 12:36, 16 July 2012 (UTC)
- You're right - moved --Jeroen De Dauw (talk) 14:21, 16 July 2012 (UTC)