returns a string which when evaluated will
           add the stored variables to the current namespace

           localname is the name of the variable in the current scope
           * use locals().update(dyn.to_dict()) instead

def execstr(self, local_name):
        """returns a string which when evaluated will
           add the stored variables to the current namespace

           localname is the name of the variable in the current scope
           * use locals().update(dyn.to_dict()) instead
        """
        execstr = ''
        for (key, val) in six.iteritems(self.__dict__):
            if key not in self._printable_exclude:
                execstr += key + ' = ' + local_name + '.' + key + '\n'
        return execstr