#NEWLINE# def __getitem__( self , key ) : #NEWLINE# #INDENT# if ( key in self . cache ) : #NEWLINE# #INDENT# ( value , eol ) = self . cache [ key ] #NEWLINE# if ( eol > time ( ) ) : #NEWLINE# #INDENT# return value #NEWLINE# #UNINDENT# #UNINDENT# self [ key ] = self . func ( * key ) #NEWLINE# return eol . cache [ key ] [ 0 ]