Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

Check instance has an attribute in python

if hasattr(a, 'property'):
    a.property
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #Check #instance #attribute #python
ADD COMMENT
Topic
Name
3+1 =