> ## Documentation Index
> Fetch the complete documentation index at: https://cdktn.io/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# CSharp: TerraformVariable

> CDKTN Core API Reference for TerraformVariable in CSharp.

* *Implements:* <a href="#cdktn.ITerraformAddressable">ITerraformAddressable</a>

## Initializers <a name="Initializers" id="cdktn.TerraformVariable.Initializer" />

```csharp theme={null}
using Io.Cdktn;

new TerraformVariable(Construct Scope, string Id, TerraformVariableConfig Config);
```

| **Name**                                                                                | **Type**                                                                          | **Description**   |
| --------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------- | ----------------- |
| <code><a href="#cdktn.TerraformVariable.Initializer.parameter.scope">Scope</a></code>   | <code>Constructs.Construct</code>                                                 | *No description.* |
| <code><a href="#cdktn.TerraformVariable.Initializer.parameter.id">Id</a></code>         | <code>string</code>                                                               | *No description.* |
| <code><a href="#cdktn.TerraformVariable.Initializer.parameter.config">Config</a></code> | <code><a href="#cdktn.TerraformVariableConfig">TerraformVariableConfig</a></code> | *No description.* |

***

### `Scope`<sup>Required</sup> <a name="Scope" id="cdktn.TerraformVariable.Initializer.parameter.scope" />

* *Type:* Constructs.Construct

***

### `Id`<sup>Required</sup> <a name="Id" id="cdktn.TerraformVariable.Initializer.parameter.id" />

* *Type:* string

***

### `Config`<sup>Required</sup> <a name="Config" id="cdktn.TerraformVariable.Initializer.parameter.config" />

* *Type:* <a href="#cdktn.TerraformVariableConfig">TerraformVariableConfig</a>

***

## Methods <a name="Methods" id="Methods" />

| **Name**                                                                                            | **Description**                                                                   |
| --------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------- |
| <code><a href="#cdktn.TerraformVariable.toString">ToString</a></code>                               | Returns a string representation of this construct.                                |
| <code><a href="#cdktn.TerraformVariable.with">With</a></code>                                       | Applies one or more mixins to this construct.                                     |
| <code><a href="#cdktn.TerraformVariable.addOverride">AddOverride</a></code>                         | *No description.*                                                                 |
| <code><a href="#cdktn.TerraformVariable.overrideLogicalId">OverrideLogicalId</a></code>             | Overrides the auto-generated logical ID with a specific ID.                       |
| <code><a href="#cdktn.TerraformVariable.resetOverrideLogicalId">ResetOverrideLogicalId</a></code>   | Resets a previously passed logical Id to use the auto-generated logical id again. |
| <code><a href="#cdktn.TerraformVariable.toHclTerraform">ToHclTerraform</a></code>                   | *No description.*                                                                 |
| <code><a href="#cdktn.TerraformVariable.toMetadata">ToMetadata</a></code>                           | *No description.*                                                                 |
| <code><a href="#cdktn.TerraformVariable.toTerraform">ToTerraform</a></code>                         | *No description.*                                                                 |
| <code><a href="#cdktn.TerraformVariable.addValidation">AddValidation</a></code>                     | *No description.*                                                                 |
| <code><a href="#cdktn.TerraformVariable.synthesizeAttributes">SynthesizeAttributes</a></code>       | *No description.*                                                                 |
| <code><a href="#cdktn.TerraformVariable.synthesizeHclAttributes">SynthesizeHclAttributes</a></code> | *No description.*                                                                 |

***

### `ToString` <a name="ToString" id="cdktn.TerraformVariable.toString" />

```csharp theme={null}
private string ToString()
```

Returns a string representation of this construct.

### `With` <a name="With" id="cdktn.TerraformVariable.with" />

```csharp theme={null}
private IConstruct With(params IMixin[] Mixins)
```

Applies one or more mixins to this construct.

Mixins are applied in order. The list of constructs is captured at the
start of the call, so constructs added by a mixin will not be visited.
Use multiple `with()` calls if subsequent mixins should apply to added
constructs.

#### `Mixins`<sup>Required</sup> <a name="Mixins" id="cdktn.TerraformVariable.with.parameter.mixins" />

* *Type:* params Constructs.IMixin\[]

The mixins to apply.

***

### `AddOverride` <a name="AddOverride" id="cdktn.TerraformVariable.addOverride" />

```csharp theme={null}
private void AddOverride(string Path, object Value)
```

#### `Path`<sup>Required</sup> <a name="Path" id="cdktn.TerraformVariable.addOverride.parameter.path" />

* *Type:* string

***

#### `Value`<sup>Required</sup> <a name="Value" id="cdktn.TerraformVariable.addOverride.parameter.value" />

* *Type:* object

***

### `OverrideLogicalId` <a name="OverrideLogicalId" id="cdktn.TerraformVariable.overrideLogicalId" />

```csharp theme={null}
private void OverrideLogicalId(string NewLogicalId)
```

Overrides the auto-generated logical ID with a specific ID.

#### `NewLogicalId`<sup>Required</sup> <a name="NewLogicalId" id="cdktn.TerraformVariable.overrideLogicalId.parameter.newLogicalId" />

* *Type:* string

The new logical ID to use for this stack element.

***

### `ResetOverrideLogicalId` <a name="ResetOverrideLogicalId" id="cdktn.TerraformVariable.resetOverrideLogicalId" />

```csharp theme={null}
private void ResetOverrideLogicalId()
```

Resets a previously passed logical Id to use the auto-generated logical id again.

### `ToHclTerraform` <a name="ToHclTerraform" id="cdktn.TerraformVariable.toHclTerraform" />

```csharp theme={null}
private object ToHclTerraform()
```

### `ToMetadata` <a name="ToMetadata" id="cdktn.TerraformVariable.toMetadata" />

```csharp theme={null}
private object ToMetadata()
```

### `ToTerraform` <a name="ToTerraform" id="cdktn.TerraformVariable.toTerraform" />

```csharp theme={null}
private object ToTerraform()
```

### `AddValidation` <a name="AddValidation" id="cdktn.TerraformVariable.addValidation" />

```csharp theme={null}
private void AddValidation(TerraformVariableValidationConfig Validation)
```

#### `Validation`<sup>Required</sup> <a name="Validation" id="cdktn.TerraformVariable.addValidation.parameter.validation" />

* *Type:* <a href="#cdktn.TerraformVariableValidationConfig">TerraformVariableValidationConfig</a>

***

### `SynthesizeAttributes` <a name="SynthesizeAttributes" id="cdktn.TerraformVariable.synthesizeAttributes" />

```csharp theme={null}
private System.Collections.Generic.IDictionary<string, object> SynthesizeAttributes()
```

### `SynthesizeHclAttributes` <a name="SynthesizeHclAttributes" id="cdktn.TerraformVariable.synthesizeHclAttributes" />

```csharp theme={null}
private System.Collections.Generic.IDictionary<string, object> SynthesizeHclAttributes()
```

## Static Functions <a name="Static Functions" id="Static Functions" />

| **Name**                                                                                  | **Description**               |
| ----------------------------------------------------------------------------------------- | ----------------------------- |
| <code><a href="#cdktn.TerraformVariable.isConstruct">IsConstruct</a></code>               | Checks if `x` is a construct. |
| <code><a href="#cdktn.TerraformVariable.isTerraformElement">IsTerraformElement</a></code> | *No description.*             |

***

### `IsConstruct` <a name="IsConstruct" id="cdktn.TerraformVariable.isConstruct" />

```csharp theme={null}
using Io.Cdktn;

TerraformVariable.IsConstruct(object X);
```

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct`
instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on
disk are seen as independent, completely different libraries. As a
consequence, the class `Construct` in each copy of the `constructs` library
is seen as a different class, and an instance of one class will not test as
`instanceof` the other class. `npm install` will not create installations
like this, but users may manually symlink construct libraries together or
use a monorepo tool: in those cases, multiple copies of the `constructs`
library can be accidentally installed, and `instanceof` will behave
unpredictably. It is safest to avoid using `instanceof`, and using
this type-testing method instead.

#### `X`<sup>Required</sup> <a name="X" id="cdktn.TerraformVariable.isConstruct.parameter.x" />

* *Type:* object

Any object.

***

### `IsTerraformElement` <a name="IsTerraformElement" id="cdktn.TerraformVariable.isTerraformElement" />

```csharp theme={null}
using Io.Cdktn;

TerraformVariable.IsTerraformElement(object X);
```

#### `X`<sup>Required</sup> <a name="X" id="cdktn.TerraformVariable.isTerraformElement.parameter.x" />

* *Type:* object

***

## Properties <a name="Properties" id="Properties" />

| **Name**                                                                                       | **Type**                                                                                                 | **Description**   |
| ---------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- | ----------------- |
| <code><a href="#cdktn.TerraformVariable.property.node">Node</a></code>                         | <code>Constructs.Node</code>                                                                             | The tree node.    |
| <code><a href="#cdktn.TerraformVariable.property.cdktfStack">CdktfStack</a></code>             | <code><a href="#cdktn.TerraformStack">TerraformStack</a></code>                                          | *No description.* |
| <code><a href="#cdktn.TerraformVariable.property.fqn">Fqn</a></code>                           | <code>string</code>                                                                                      | *No description.* |
| <code><a href="#cdktn.TerraformVariable.property.friendlyUniqueId">FriendlyUniqueId</a></code> | <code>string</code>                                                                                      | *No description.* |
| <code><a href="#cdktn.TerraformVariable.property.booleanValue">BooleanValue</a></code>         | <code><a href="#cdktn.IResolvable">IResolvable</a></code>                                                | *No description.* |
| <code><a href="#cdktn.TerraformVariable.property.listValue">ListValue</a></code>               | <code>string\[]</code>                                                                                   | *No description.* |
| <code><a href="#cdktn.TerraformVariable.property.numberValue">NumberValue</a></code>           | <code>double</code>                                                                                      | *No description.* |
| <code><a href="#cdktn.TerraformVariable.property.stringValue">StringValue</a></code>           | <code>string</code>                                                                                      | *No description.* |
| <code><a href="#cdktn.TerraformVariable.property.value">Value</a></code>                       | <code>object</code>                                                                                      | *No description.* |
| <code><a href="#cdktn.TerraformVariable.property.default">Default</a></code>                   | <code>object</code>                                                                                      | *No description.* |
| <code><a href="#cdktn.TerraformVariable.property.description">Description</a></code>           | <code>string</code>                                                                                      | *No description.* |
| <code><a href="#cdktn.TerraformVariable.property.nullable">Nullable</a></code>                 | <code>bool</code>                                                                                        | *No description.* |
| <code><a href="#cdktn.TerraformVariable.property.sensitive">Sensitive</a></code>               | <code>bool</code>                                                                                        | *No description.* |
| <code><a href="#cdktn.TerraformVariable.property.type">Type</a></code>                         | <code>string</code>                                                                                      | *No description.* |
| <code><a href="#cdktn.TerraformVariable.property.validation">Validation</a></code>             | <code><a href="#cdktn.TerraformVariableValidationConfig">TerraformVariableValidationConfig</a>\[]</code> | *No description.* |

***

### `Node`<sup>Required</sup> <a name="Node" id="cdktn.TerraformVariable.property.node" />

```csharp theme={null}
public Node Node { get; }
```

* *Type:* Constructs.Node

The tree node.

***

### `CdktfStack`<sup>Required</sup> <a name="CdktfStack" id="cdktn.TerraformVariable.property.cdktfStack" />

```csharp theme={null}
public TerraformStack CdktfStack { get; }
```

* *Type:* <a href="#cdktn.TerraformStack">TerraformStack</a>

***

### `Fqn`<sup>Required</sup> <a name="Fqn" id="cdktn.TerraformVariable.property.fqn" />

```csharp theme={null}
public string Fqn { get; }
```

* *Type:* string

***

### `FriendlyUniqueId`<sup>Required</sup> <a name="FriendlyUniqueId" id="cdktn.TerraformVariable.property.friendlyUniqueId" />

```csharp theme={null}
public string FriendlyUniqueId { get; }
```

* *Type:* string

***

### `BooleanValue`<sup>Required</sup> <a name="BooleanValue" id="cdktn.TerraformVariable.property.booleanValue" />

```csharp theme={null}
public IResolvable BooleanValue { get; }
```

* *Type:* <a href="#cdktn.IResolvable">IResolvable</a>

***

### `ListValue`<sup>Required</sup> <a name="ListValue" id="cdktn.TerraformVariable.property.listValue" />

```csharp theme={null}
public string[] ListValue { get; }
```

* *Type:* string\[]

***

### `NumberValue`<sup>Required</sup> <a name="NumberValue" id="cdktn.TerraformVariable.property.numberValue" />

```csharp theme={null}
public double NumberValue { get; }
```

* *Type:* double

***

### `StringValue`<sup>Required</sup> <a name="StringValue" id="cdktn.TerraformVariable.property.stringValue" />

```csharp theme={null}
public string StringValue { get; }
```

* *Type:* string

***

### `Value`<sup>Required</sup> <a name="Value" id="cdktn.TerraformVariable.property.value" />

```csharp theme={null}
public object Value { get; }
```

* *Type:* object

***

### `Default`<sup>Optional</sup> <a name="Default" id="cdktn.TerraformVariable.property.default" />

```csharp theme={null}
public object Default { get; }
```

* *Type:* object

***

### `Description`<sup>Optional</sup> <a name="Description" id="cdktn.TerraformVariable.property.description" />

```csharp theme={null}
public string Description { get; }
```

* *Type:* string

***

### `Nullable`<sup>Optional</sup> <a name="Nullable" id="cdktn.TerraformVariable.property.nullable" />

```csharp theme={null}
public bool Nullable { get; }
```

* *Type:* bool

***

### `Sensitive`<sup>Optional</sup> <a name="Sensitive" id="cdktn.TerraformVariable.property.sensitive" />

```csharp theme={null}
public bool Sensitive { get; }
```

* *Type:* bool

***

### `Type`<sup>Optional</sup> <a name="Type" id="cdktn.TerraformVariable.property.type" />

```csharp theme={null}
public string Type { get; }
```

* *Type:* string

***

### `Validation`<sup>Optional</sup> <a name="Validation" id="cdktn.TerraformVariable.property.validation" />

```csharp theme={null}
public TerraformVariableValidationConfig[] Validation { get; }
```

* *Type:* <a href="#cdktn.TerraformVariableValidationConfig">TerraformVariableValidationConfig</a>\[]

***
