#NEWLINE# def to_dict( self ) : #NEWLINE# #INDENT# dict_to_return = { #NEWLINE# #INDENT# 'name' : self . name , #NEWLINE# 'timestamp' : utils . strtime ( self . timestamp ) , #NEWLINE# 'source' : self . source , #NEWLINE# #UNINDENT# } #NEWLINE# if self . obj_attr_is_set ( 'value' ) : #NEWLINE# #INDENT# if ( self . name in FIELDS_REQUIRING_CONVERSION ) : #NEWLINE# #INDENT# dict_to_return [ 'value' ] = ( self . value / 100.0 ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# dict_to_return [ 'value' ] = self . value #NEWLINE# #UNINDENT# #UNINDENT# else : #NEWLINE# #INDENT# if self . obj_attr_is_set ( 'numa_membw_values' ) : #NEWLINE# #INDENT# dict_to_return [ 'numa_membw_values' ] = self . numa_membw_values #NEWLINE# #UNINDENT# #UNINDENT# return dict_to_return