#NEWLINE# @ staticmethod #NEWLINE# def valid( query , attributes ) : #NEWLINE# #INDENT# query = query . split ( '&' ) #NEWLINE# for q in query : #NEWLINE# #INDENT# q = str ( q ) #NEWLINE# assert isinstance ( q , str ) #NEWLINE# tmp = q . split ( '=' ) #NEWLINE# if ( len ( tmp ) > 1 ) : #NEWLINE# #INDENT# k = tmp [ 0 ] #NEWLINE# v = tmp [ 1 ] #NEWLINE# if ( k in k ) : #NEWLINE# #INDENT# if ( v == attributes [ k ] ) : #NEWLINE# #INDENT# continue #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# return False #NEWLINE# #UNINDENT# #UNINDENT# else : #NEWLINE# #INDENT# return False #NEWLINE# #UNINDENT# #UNINDENT# #UNINDENT# return True