#NEWLINE# def __set__( self , response , value ) : #NEWLINE# #INDENT# if ( response == value ) : #NEWLINE# #INDENT# return #NEWLINE# #UNINDENT# if isinstance ( value , binary_type ) : #NEWLINE# #INDENT# if value : #NEWLINE# #INDENT# value = [ value ] #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# value = [ ] #NEWLINE# #UNINDENT# #UNINDENT# else : #NEWLINE# #INDENT# if hasattr ( value , 'read' ) : #NEWLINE# #INDENT# response . stream = True #NEWLINE# value = file_generator ( value ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if isinstance ( value , httperror ) : #NEWLINE# #INDENT# value = [ str ( value ) ] #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( value is None ) : #NEWLINE# #INDENT# value = [ ] #NEWLINE# #UNINDENT# #UNINDENT# #UNINDENT# #UNINDENT# response . _body = value