#NEWLINE# def process_min_max_values( self , component ) : #NEWLINE# #INDENT# 'Agent keeps track of previous values, so compute the differences for\n        min/max values.\n\n        :param dict component: The component to calc min/max values for\n\n        ' #NEWLINE# guid = component [ 'guid' ] #NEWLINE# name = component [ 'name' ] #NEWLINE# if ( guid not in self . min_max_values . keys ( ) ) : #NEWLINE# #INDENT# self . min_max_values [ guid ] = dict ( ) #NEWLINE# #UNINDENT# if ( name not in self . min_max_values [ guid ] . keys ( ) ) : #NEWLINE# #INDENT# self . min_max_values [ guid ] [ name ] = dict ( ) #NEWLINE# #UNINDENT# for metric in component [ 'metrics' ] : #NEWLINE# #INDENT# ( min_val , max_val ) = self . min_max_values [ guid ] [ name ] . get ( metric , ( None , None ) ) #NEWLINE# value = component [ 'metrics' ] [ metric ] [ 'total' ] #NEWLINE# if ( ( min_val is not None ) and ( min_val > value ) ) : #NEWLINE# #INDENT# min_val = value #NEWLINE# #UNINDENT# if ( ( max_val is None ) or ( max_val < value ) ) : #NEWLINE# #INDENT# max_val = value #NEWLINE# #UNINDENT# if ( component [ 'metrics' ] [ metric ] [ 'min' ] is None ) : #NEWLINE# #INDENT# component [ 'metrics' ] [ metric ] [ 'min' ] = ( min_val or value ) #NEWLINE# #UNINDENT# if ( component [ 'metrics' ] [ metric ] [ 'max' ] is None ) : #NEWLINE# #INDENT# component [ 'metrics' ] [ metric ] [ 'max' ] = max_val #NEWLINE# #UNINDENT# self . min_max_values [ guid ] [ name ] [ metric ] = ( min_val , max_val )