Esempio n. 1
0
    def write(self, op=None):
        '''Writes PSI map to file

        Arguments:
        op -- output pathname (default: None)'''
        # Import XML file writer
        from psiutils import toxmlfile
        # Use output attribute if not overridden
        if op == None: op = self.output
        # Append .psi extension if not specified
        if op.find('.psi') == -1: op = ''.join([op, '.psi'])
        # Write the file
        toxmlfile(self._doc, op)
Esempio n. 2
0
 def _exportResourcesDW(self):
     for i in self._exports:
         try: toxmlfile(self._exports.get(i), i)
         except IOError:
             try:
                 if i.find('Templates'): 
                     toxmlfile(self._exports.get(i), i[1:])
             except IOError:
                 if i.find('Templates'):
                     os.mkdir('Templates')
                     toxmlfile(self._exports.get(i), i[1:])
Esempio n. 3
0
 def _exportResources(self):
     for i in self._exports: toxmlfile(self._exports.get(i), i)