Rename NodeRefreshableResource to NodeRefreshableResourceInstance

In prep for NodeRefreshableResource becoming an
NodeAbstractCountResource and implementing GraphNodeDynamicExpandable.
This commit is contained in:
Chris Marchesi 2017-04-29 12:08:04 -07:00 committed by Martin Atkins
parent 89b4d0784c
commit dfb5be2413
2 changed files with 6 additions and 6 deletions

View File

@ -57,7 +57,7 @@ func (b *RefreshGraphBuilder) Steps() []GraphTransformer {
}
concreteResource := func(a *NodeAbstractResource) dag.Vertex {
return &NodeRefreshableResource{
return &NodeRefreshableResourceInstance{
NodeAbstractResource: a,
}
}

View File

@ -6,19 +6,19 @@ import (
"github.com/hashicorp/terraform/config"
)
// NodeRefreshableResource represents a resource that is "applyable":
// NodeRefreshableResourceInstance represents a resource that is "applyable":
// it is ready to be applied and is represented by a diff.
type NodeRefreshableResource struct {
type NodeRefreshableResourceInstance struct {
*NodeAbstractResource
}
// GraphNodeDestroyer
func (n *NodeRefreshableResource) DestroyAddr() *ResourceAddress {
func (n *NodeRefreshableResourceInstance) DestroyAddr() *ResourceAddress {
return n.Addr
}
// GraphNodeEvalable
func (n *NodeRefreshableResource) EvalTree() EvalNode {
func (n *NodeRefreshableResourceInstance) EvalTree() EvalNode {
// Eval info is different depending on what kind of resource this is
switch mode := n.Addr.Mode; mode {
case config.ManagedResourceMode:
@ -44,7 +44,7 @@ func (n *NodeRefreshableResource) EvalTree() EvalNode {
}
}
func (n *NodeRefreshableResource) evalTreeManagedResource() EvalNode {
func (n *NodeRefreshableResourceInstance) evalTreeManagedResource() EvalNode {
addr := n.NodeAbstractResource.Addr
// stateId is the ID to put into the state