예제 #1
0
 def is_valid_base_for_new(base):
     '''
     Checks whether base is valid.
     '''
     try:
         xlifffile.parsefile(base)
         return True
     except Exception:
         return False
예제 #2
0
 def is_valid_base_for_new(base):
     '''
     Checks whether base is valid.
     '''
     try:
         xlifffile.parsefile(base)
         return True
     except Exception:
         return False
예제 #3
0
 def create_new_file(cls, filename, code, base):
     """Handles creation of new translation file."""
     content = xlifffile.parsefile(base)
     content.settargetlanguage(code)
     content.savefile(filename)
예제 #4
0
 def create_new_file(cls, filename, code, base):
     """Handles creation of new translation file."""
     content = xlifffile.parsefile(base)
     content.settargetlanguage(code)
     content.savefile(filename)