mirror of
https://github.com/opentofu/opentofu.git
synced 2024-12-23 07:33:32 -06:00
cb2e9119aa
Signed-off-by: namgyalangmo <75657887+namgyalangmo@users.noreply.github.com>
24 lines
538 B
Go
24 lines
538 B
Go
// Copyright (c) The OpenTofu Authors
|
|
// SPDX-License-Identifier: MPL-2.0
|
|
// Copyright (c) 2023 HashiCorp, Inc.
|
|
// SPDX-License-Identifier: MPL-2.0
|
|
|
|
package addrs
|
|
|
|
// CountAttr is the address of an attribute of the "count" object in
|
|
// the interpolation scope, like "count.index".
|
|
type CountAttr struct {
|
|
referenceable
|
|
Name string
|
|
}
|
|
|
|
func (ca CountAttr) String() string {
|
|
return "count." + ca.Name
|
|
}
|
|
|
|
func (ca CountAttr) UniqueKey() UniqueKey {
|
|
return ca // A CountAttr is its own UniqueKey
|
|
}
|
|
|
|
func (ca CountAttr) uniqueKeySigil() {}
|