Implemented 'ifDefinedOtherwise'; minor optimization of 'isDefined'
implementation.
Added 'ifDefinedOtherwise' tests.