#NEWLINE# def _set_singleton_option_value( self , option , value , append = False , allow_stream = True , set_dep = True ) : #NEWLINE# #INDENT# 'Set a single value of the given options and create\n        an edge and an option link on the edge if the value is another option\n        or another node.\n\n        :param option: the option of this nodes tool that will be updated\n        :type option: jip.options.Option\n        :param value: the new value\n        :type value: object\n        :param append: if set to true, the value is appended to the list of\n                       values for the given option\n        :type value: bool\n        ' #NEWLINE# def _force_stream( target , source ) : #NEWLINE# #INDENT# return ( target . streamable and source . streamable and source . is_stream ( ) ) #NEWLINE# #UNINDENT# if isinstance ( value , Node ) : #NEWLINE# #INDENT# value = value . _tool . options . get_default_output ( ) #NEWLINE# #UNINDENT# if isinstance ( value , Option ) : #NEWLINE# #INDENT# option . dependency = True #NEWLINE# new_value = value #NEWLINE# if ( allow_stream or _force_stream ( option , value ) ) : #NEWLINE# #INDENT# if ( option . streamable and value . streamable ) : #NEWLINE# #INDENT# new_value = value . default #NEWLINE# allow_stream = True #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# allow_stream = False #NEWLINE# #UNINDENT# #UNINDENT# if ( not append ) : #NEWLINE# #INDENT# option . set ( new_value ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# option . append ( new_value ) #NEWLINE# #UNINDENT# edge = self . _graph . add_edge ( value . source , self . _tool ) #NEWLINE# if edge : #NEWLINE# #INDENT# edge . add_link ( value , option , allow_stream = allow_stream ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# self . _pipeline_options . append ( { #NEWLINE# #INDENT# 'source' : value . source , #NEWLINE# 'option' : option , #NEWLINE# 'source_option' : value , #NEWLINE# 'stream' : allow_stream , #NEWLINE# #UNINDENT# } ) #NEWLINE# #UNINDENT# #UNINDENT# else : #NEWLINE# #INDENT# if ( not append ) : #NEWLINE# #INDENT# if set_dep : #NEWLINE# #INDENT# option . dependecy = False #NEWLINE# #UNINDENT# option . set ( value ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# option . append ( value )