DotEnvValue Class
Definition
Represents a string-valued leaf in a mutable DotEnv document tree.
public sealed class DotEnvValue : DotEnvNode
- Inheritance
-
DotEnvValue
- Inherited Members
- Extension Methods
Constructors
DotEnvValue(string)
Initializes a new instance of the DotEnvValue class with the supplied value.
public DotEnvValue(string value)
Parameters
valuestringThe string value.
Exceptions
- ArgumentNullException
Thrown when
valueis null.
Properties
Value
Gets or sets the string value.
public string Value { get; set; }
Property Value
Exceptions
- ArgumentNullException
Thrown when the assigned value is null.
ValueKind
Gets the value kind of this node.
public override DotEnvValueKind ValueKind { get; }
Property Value
- DotEnvValueKind
The node's DotEnvValueKind.
Methods
DeepClone()
Creates a deep copy of this node.
public override DotEnvNode DeepClone()
Returns
- DotEnvNode
The cloned node.
WriteTo(ref Utf8DotEnvWriter)
Writes this node's DotEnv representation to the supplied writer.
public override void WriteTo(ref Utf8DotEnvWriter writer)
Parameters
writerUtf8DotEnvWriterThe writer that receives the DotEnv bytes.
Applies to
| Product | Versions |
|---|---|
| .NET | 8, 10 |