<s> import collections <EOL> import copy <EOL> from . Utils import _write_complex_object <EOL> class ExceptionDetails ( object ) : <EOL> """<STR_LIT>""" <EOL> _defaults = collections . OrderedDict ( [ <EOL> ( '<STR_LIT:id>' , None ) , <EOL> ( '<STR_LIT>' , None ) , <EOL> ( '<STR_LIT>' , None ) , <EOL> ( '<STR_LIT:message>' , None ) , <EOL> ( '<STR_LIT>' , True ) , <EOL> ( '<STR_LIT>' , None ) , <EOL> ( '<STR_LIT>' , [ ] ) <EOL> ] ) <EOL> def __init__ ( self ) : <EOL> """<STR_LIT>""" <EOL> self . _values = { <EOL> '<STR_LIT>' : None , <EOL> '<STR_LIT:message>' : None , <EOL> '<STR_LIT>' : True , <EOL> } <EOL> self . _initialize ( ) <EOL> @ property <EOL> def id ( self ) : <EOL> """<STR_LIT>""" <EOL> if '<STR_LIT:id>' in self . _values : <EOL> return self . _values [ '<STR_LIT:id>' ] <EOL> return self . _defaults [ '<STR_LIT:id>' ] <EOL> @ id . setter <EOL> def id ( self , value ) : <EOL> """<STR_LIT>""" <EOL> if value == self . _defaults [ '<STR_LIT:id>' ] and '<STR_LIT:id>' in self . _values : <EOL> del self . _values [ '<STR_LIT:id>' ] <EOL> else : <EOL> self . _values [ '<STR_LIT:id>' ] = value <EOL> @ property <EOL> def outer_id ( self ) : <EOL> """<STR_LIT>""" <EOL> if '<STR_LIT>' in self . _values : <EOL> return self . _values [ '<STR_LIT>' ] <EOL> return self . _defaults [ '<STR_LIT>' ] <EOL> @ outer_id . setter <EOL> def outer_id ( self , value ) : <EOL> """<STR_LIT>""" <EOL> if value == self . _defaults [ '<STR_LIT>' ] and '<STR_LIT>' in self . _values : <EOL> del self . _values [ '<STR_LIT>' ] <EOL> else : <EOL> self . _values [ '<STR_LIT>' ] = value <EOL> @ property <EOL> def type_name ( self ) : <EOL> """<STR_LIT>""" <EOL> return self . _values [ '<STR_LIT>' ] <EOL> @ type_name . setter <EOL> def type_name ( self , value ) : <EOL> """<STR_LIT>""" <EOL> self . _values [ '<STR_LIT>' ] = value <EOL> @ property <EOL> def message ( self ) : <EOL> """<STR_LIT>""" <EOL> return self . _values [ '<STR_LIT:message>' ] <EOL> @ message . setter <EOL> def message ( self , value ) : <EOL> """<STR_LIT>""" <EOL> self . _values [ '<STR_LIT:message>' ] = value <EOL> @ property <EOL> def has_full_stack ( self ) : <EOL> """<STR_LIT>""" <EOL> if '<STR_LIT>' in self . _values : <EOL> return self . _values [ '<STR_LIT>' ] <EOL> return self . _defaults [ '<STR_LIT>' ] <EOL> @ has_full_stack . setter <EOL> def has_full_stack ( self , value ) : <EOL> """<STR_LIT>""" <EOL> if value == self . _defaults [ '<STR_LIT>' ] and '<STR_LIT>' in self . _values : <EOL> del self . _values [ '<STR_LIT>' ] <EOL> else : <EOL> self . _values [ '<STR_LIT>' ] = value <EOL> @ property <EOL> def stack ( self ) : <EOL> """<STR_LIT>""" <EOL> if '<STR_LIT>' in self . _values : <EOL> return self . _values [ '<STR_LIT>' ] <EOL> return self . _defaults [ '<STR_LIT>' ] <EOL> @ stack . setter <EOL> def stack ( self , value ) : <EOL> """<STR_LIT>""" <EOL> if value == self . _defaults [ '<STR_LIT>' ] and '<STR_LIT>' in self . _values : <EOL> del self . _values [ '<STR_LIT>' ] <EOL> else : <EOL> self . _values [ '<STR_LIT>' ] = value <EOL> @ property <EOL> def parsed_stack ( self ) : <EOL> """<STR_LIT>""" <EOL> if '<STR_LIT>' in self . _values : <EOL> return self . _values [ '<STR_LIT>' ] <EOL> self . _values [ '<STR_LIT>' ] = copy . deepcopy ( self . _defaults [ '<STR_LIT>' ] ) <EOL> return self . _values [ '<STR_LIT>' ] <EOL> @ parsed_stack . setter <EOL> def parsed_stack ( self , value ) : <EOL> """<STR_LIT>""" <EOL> if value == self . _defaults [ '<STR_LIT>' ] and '<STR_LIT>' in self . _values : <EOL> del self . _values [ '<STR_LIT>' ] <EOL> else : <EOL> self . _values [ '<STR_LIT>' ] = value <EOL> def _initialize ( self ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> def write ( self ) : <EOL> """<STR_LIT>""" <EOL> return _write_complex_object ( self . _defaults , self . _values ) </s>
