code: public void setCosts(Costs nodeCosts) {
  		// set the node costs
  		this.nodeCosts = nodeCosts;
  		
  		// the cumulative costs are the node costs plus the costs of all inputs
  		this.cumulativeCosts = nodeCosts.clone();
  		
  		// add all the normal inputs
  		for (Iterator<PlanNode> preds = getPredecessors(); preds.hasNext();) {
  			Costs parentCosts = preds.next().getCumulativeCostsShare();
  			if (parentCosts != null) {
  				this.cumulativeCosts.addCosts(parentCosts);
  			} else {
  				throw new CompilerException("Trying to set the costs of an operator before the predecessor costs are computed.");
  			}
  		}
  		
  		// add all broadcast variable inputs
  		if (this.broadcastInputs != null) {
  			for (NamedChannel nc : this.broadcastInputs) {
  				Costs bcInputCost = nc.getSource().getCumulativeCostsShare();
  				if (bcInputCost != null) {
  					this.cumulativeCosts.addCosts(bcInputCost);
  				} else {
  					throw new CompilerException("Trying to set the costs of an operator before the broadcast input costs are computed.");
  				}
  			}
  		}
  	}
docs: Sets the basic cost for this node to the given value, and sets the cumulative costs
  to those costs plus the cost shares of all inputs (regular and broadcast).
  
  @param nodeCosts	 The already knows costs for this node
  (this cost a produces by a concrete {@code OptimizerNode} subclass.