o
    biS                     @   s`   d dl Z d dlmZmZmZmZmZ d dlmZ d dl	m
Z
 d dlmZ eG dd deZdS )    N)AnyDictListUnionTuple)DAGNodeget_dag_node_str)DeveloperAPIc                
       s   e Zd ZdZ	ddeee ee f dee	e
f f fddZdeejdf fd	d
Zdee
 dee	e
f dee	e
f dee	e
f ddf
ddZde	fddZ  ZS )MultiOutputNodezARay dag node used in DAG building API to mark the endpoint of DAGNargsother_args_to_resolvec                    sL   t |tr	t|}t |tstdt| dt j|i i |p!i d d S )NzInvalid input type for `args`, .)r   )
isinstancetuplelist
ValueErrortypesuper__init__)selfr   r   	__class__ G/home/ubuntu/.local/lib/python3.10/site-packages/ray/dag/output_node.pyr      s   


zMultiOutputNode.__init__returnzray.actor.ActorHandlec                 O   s   | j S N)_bound_args)r   r   kwargsr   r   r   _execute_impl   s   zMultiOutputNode._execute_implnew_args
new_kwargsnew_optionsnew_other_args_to_resolver   c                 C   s
   t ||S )z3Return a copy of this node with the given new args.)r   )r   r    r!   r"   r#   r   r   r   
_copy_impl"   s   
zMultiOutputNode._copy_implc                 C   s
   t | dS )N__MultiOutputNode__r   )r   r   r   r   __str__,   s   
zMultiOutputNode.__str__r   )__name__
__module____qualname____doc__r   r   r   r   r   strr   r   ray	ObjectRefr   r$   r&   __classcell__r   r   r   r   r   	   s.    






r   )r,   typingr   r   r   r   r   ray.dagr   ray.dag.format_utilsr	   ray.util.annotationsr
   r   r   r   r   r   <module>   s    