exceptions.py 996 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. # -*- coding: utf-8 -*-
  2. """
  3. Copyright (c) 2010-2014 pyrod
  4. @author: Han Xu
  5. @mail: xuhan@mail.ustc.edu.cn
  6. """
  7. # Codes are free to use
  8. from __future__ import absolute_import
  9. """Definitions for pyrod shared exception classes."""
  10. class Illegal_Filename_Exception(Exception):
  11. """Error for Illegal raw data and parameters names
  12. raw data name: hkl.dat or hkl.xlsx, hk is variable, l is str
  13. parameters name: parameters_xxxx.xlsx"""
  14. class Illegal_Sheetname_Exception(Exception):
  15. """Error for Illegal sheet names
  16. sheet name: substrate,slab1,slab2,.. slabxx,factors"""
  17. class Excel_Load_Exception(Exception):
  18. """Error for loading data"""
  19. class Data_Base_Exception(Exception):
  20. """inputs are not stored in data base"""
  21. class Data_Format_Exception(Exception):
  22. """Error for any data format inconsistencies."""
  23. class Data_Match_Exception(Exception):
  24. """Error for data match."""
  25. class Data_Load_Exception(Exception):
  26. """Error for data loading."""