Web Maestro Clay
On Apr 7, 2005, at 9:07 AM, Glen Mazza wrote:
Jeremias,
I do not fully understand the business logic for tables--so what I am saying here may not be relevant.
But if cell should *never* be null (i.e., the caller of this method is very sloppily written), please let the methods NPE, raise IndexOutOfBoundsError, InvalidStateException, etc., so we can immediately be informed of the caller's incompetence at the point of error and work on that right away.
Make sure we don't quietly return null so that the problem will resurface several classes further downstream where it presumably would be much harder to track. If we have to put a temporary band-aid in, best to put it with caller (i.e., have it not call the method if "cell" is null), not the callee.
Thanks, Glen
--- [EMAIL PROTECTED] wrote:cell.getCommonBorderPaddingBackground().getBorderInfo(side);+ public BorderInfo getOriginalBorderInfoForCell(int side) { + if (cell != null) { + return
+ } else { + return null; + } + }
Web Maestro Clay -- <[EMAIL PROTECTED]> - <http://homepage.mac.com/webmaestro/> My religion is simple. My religion is kindness. - HH The 14th Dalai Lama of Tibet