#NEWLINE# @ classmethod #NEWLINE# def dict_from_line( cls , line , keys = fstab_keys ) : #NEWLINE# #INDENT# if ( len ( keys ) != 6 ) : #NEWLINE# #INDENT# raise ValueError ( 'Invalid key array: {0}' . format ( keys ) ) #NEWLINE# #UNINDENT# if line . startswith ( '#' ) : #NEWLINE# #INDENT# raise cls . ParseError ( 'Comment!' ) #NEWLINE# #UNINDENT# comps = line . split ( ) #NEWLINE# if ( len ( comps ) != 6 ) : #NEWLINE# #INDENT# raise cls . ParseError ( 'Invalid Entry!' ) #NEWLINE# #UNINDENT# return dict ( zip ( keys , comps ) )