github.com/jayaramimmaneni/terraform@v0.11.12-beta1/terraform/graph_builder_input.go (about)

     1  package terraform
     2  
     3  import (
     4  	"github.com/hashicorp/terraform/dag"
     5  )
     6  
     7  // InputGraphBuilder creates the graph for the input operation.
     8  //
     9  // Unlike other graph builders, this is a function since it currently modifies
    10  // and is based on the PlanGraphBuilder. The PlanGraphBuilder passed in will be
    11  // modified and should not be used for any other operations.
    12  func InputGraphBuilder(p *PlanGraphBuilder) GraphBuilder {
    13  	// We're going to customize the concrete functions
    14  	p.CustomConcrete = true
    15  
    16  	// Set the provider to the normal provider. This will ask for input.
    17  	p.ConcreteProvider = func(a *NodeAbstractProvider) dag.Vertex {
    18  		return &NodeApplyableProvider{
    19  			NodeAbstractProvider: a,
    20  		}
    21  	}
    22  
    23  	// We purposely don't set any more concrete fields since the remainder
    24  	// should be no-ops.
    25  
    26  	return p
    27  }