UndefinedObject.st
changeset 16908 25523cfdfa62
parent 16721 5fe358a0c941
child 18120 e3a375d5f6a8
child 18480 d024e283fb68
equal deleted inserted replaced
16907:402df2d3c1d7 16908:25523cfdfa62
   106 
   106 
   107     "Created: 3.1.1997 / 15:05:48 / cg"
   107     "Created: 3.1.1997 / 15:05:48 / cg"
   108     "Modified: 3.1.1997 / 15:06:15 / cg"
   108     "Modified: 3.1.1997 / 15:06:15 / cg"
   109 ! !
   109 ! !
   110 
   110 
       
   111 
   111 !UndefinedObject class methodsFor:'queries'!
   112 !UndefinedObject class methodsFor:'queries'!
   112 
   113 
   113 canBeSubclassed
   114 canBeSubclassed
   114     "return true, if its allowed to create subclasses of the receiver.
   115     "return true, if its allowed to create subclasses of the receiver.
   115      Return false here - since it is NOT possible for UndefinedObject.
   116      Return false here - since it is NOT possible for UndefinedObject.
   148      Here, true is returned for myself, false for subclasses."
   149      Here, true is returned for myself, false for subclasses."
   149 
   150 
   150     ^ self == UndefinedObject
   151     ^ self == UndefinedObject
   151 
   152 
   152 ! !
   153 ! !
       
   154 
       
   155 
       
   156 
       
   157 
   153 
   158 
   154 
   159 
   155 !UndefinedObject methodsFor:'converting'!
   160 !UndefinedObject methodsFor:'converting'!
   156 
   161 
   157 asBoolean
   162 asBoolean
   669     ^ true
   674     ^ true
   670 
   675 
   671     "Modified: / 13.11.2001 / 13:28:15 / cg"
   676     "Modified: / 13.11.2001 / 13:28:15 / cg"
   672 !
   677 !
   673 
   678 
       
   679 isNotNil
       
   680     "Return true, if the receiver not nil.
       
   681      Since I am definitely nil, unconditionally return false here.      
       
   682      the receiver is definitely not nil here, so unconditionally return false."
       
   683 
       
   684     ^ false
       
   685 
       
   686     "Created: / 26-10-2014 / 01:30:15 / Jan Vrany <jan.vrany@fit.cvut.cz>"
       
   687 !
       
   688 
   674 notEmptyOrNil
   689 notEmptyOrNil
   675     "Squeak compatibility:
   690     "Squeak compatibility:
   676      return true if I am neither nil nor an empty collection."
   691      return true if I am neither nil nor an empty collection."
   677 
   692 
   678     ^ false
   693     ^ false
   704     "dispatch for visitor pattern; send #visitNil:with: to aVisitor."
   719     "dispatch for visitor pattern; send #visitNil:with: to aVisitor."
   705 
   720 
   706     ^ aVisitor visitNilWith:aParameter
   721     ^ aVisitor visitNilWith:aParameter
   707 ! !
   722 ! !
   708 
   723 
       
   724 
   709 !UndefinedObject class methodsFor:'documentation'!
   725 !UndefinedObject class methodsFor:'documentation'!
   710 
   726 
   711 version
   727 version
   712     ^ '$Header: /cvs/stx/stx/libbasic/UndefinedObject.st,v 1.77 2014-07-09 16:20:27 cg Exp $'
   728     ^ '$Header: /cvs/stx/stx/libbasic/UndefinedObject.st,v 1.78 2014-10-26 01:31:37 vrany Exp $'
   713 !
   729 !
   714 
   730 
   715 version_CVS
   731 version_CVS
   716     ^ '$Header: /cvs/stx/stx/libbasic/UndefinedObject.st,v 1.77 2014-07-09 16:20:27 cg Exp $'
   732     ^ '$Header: /cvs/stx/stx/libbasic/UndefinedObject.st,v 1.78 2014-10-26 01:31:37 vrany Exp $'
   717 ! !
   733 ! !
   718 
   734 
   719 
   735 
   720 UndefinedObject initialize!
   736 UndefinedObject initialize!