Show
Ignore:
Timestamp:
03/16/10 14:18:17 (6 months ago)
Author:
tal
Message:
Added a __contains__ method.
Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • packages/vanilla/trunk/Lib/vanilla/vanillaList.py

    r602 r709  
    878878        self._arrayController.removeObjectAtArrangedObjectIndex_(index) 
    879879 
     880    def __contains__(self, item): 
     881        item = self._wrapItem(item) 
     882        return self._arrayController.content().containsObject_(item) 
     883 
    880884    def append(self, item): 
    881885        item = self._wrapItem(item)