#NEWLINE# def store_directory_structure( self , path ) : #NEWLINE# #INDENT# '\n        recursivelly traverse directory and store it in format\n        that can be given to create_structure_from_variable()\n        ' #NEWLINE# d = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } #NEWLINE# for ( base , dirs , files ) in os . walk ( self ) : #NEWLINE# #INDENT# d [ base ] = None #NEWLINE# for i in files : #NEWLINE# #INDENT# fn = join ( base , i ) #NEWLINE# f = open ( fn , 'r' ) #NEWLINE# d [ fn ] = f . read ( ) #NEWLINE# f . close ( ) #NEWLINE# #UNINDENT# #UNINDENT# return d . items ( )