# ResourceCommandSnapshot

- Kind: `record`
- Package: [Aspire.Hosting](/reference/api/csharp/aspire.hosting.md)
- Version: `13.3.0`
- Namespace: `Aspire.Hosting.ApplicationModel`
- Target framework: `net8.0`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)
- Implements: `IEquatable<ResourceCommandSnapshot>`

A snapshot of a resource command.

## Definition

```csharp
namespace Aspire.Hosting.ApplicationModel;

public sealed record ResourceCommandSnapshot
    : System.IEquatable<Aspire.Hosting.ApplicationModel.ResourceCommandSnapshot>
{
    // ...
}
```

## Constructors

- [ResourceCommandSnapshot(string, ResourceCommandState, string, string?, object?, string?, string?, IconVariant?, bool)](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/constructors.md#constructor-string-resourcecommandstate-string-string-object-string-string-iconvariant-bool) -- A snapshot of a resource command.

## Properties

- [ConfirmationMessage](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/properties.md#confirmationmessage) : `string?` `get; init` -- When a confirmation message is specified, the UI will prompt with an OK/Cancel dialog and the confirmation message before starting the command.
- [DisplayDescription](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/properties.md#displaydescription) : `string?` `get; init` -- Optional description of the command, to be shown in the UI. Could be used as a tooltip. May be localized.
- [DisplayName](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/properties.md#displayname) : `string` `get; init` -- The display name visible in UI for the command.
- [IconName](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/properties.md#iconname) : `string?` `get; init` -- The icon name for the command. The name should be a valid FluentUI icon name. https://aka.ms/fluentui-system-icons
- [IconVariant](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/properties.md#iconvariant) : [IconVariant?](/reference/api/csharp/aspire.hosting/iconvariant.md) `get; init` -- The icon variant.
- [IsHighlighted](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/properties.md#ishighlighted) : `bool` `get; init` -- A flag indicating whether the command is highlighted in the UI.
- [Name](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/properties.md#name) : `string` `get; init` -- The name of command. The name uniquely identifies the command.
- [Parameter](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/properties.md#parameter) : `object?` `get; init` -- Optional parameter that configures the command in some way. Clients must return any value provided by the server when invoking the command.
- [State](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/properties.md#state) : [ResourceCommandState](/reference/api/csharp/aspire.hosting/resourcecommandstate.md) `get; init` -- The state of the command.

## Methods

- [<Clone>$](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/methods.md#clone) : [ResourceCommandSnapshot](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot.md)
- [Deconstruct(string, ResourceCommandState, string, string?, object?, string?, string?, IconVariant?, bool)](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/methods.md#deconstruct-string-resourcecommandstate-string-string-object-string-string-iconvariant-bool)
- [Equals(object?)](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/methods.md#equals-object) : `bool` -- Determines whether the specified object is equal to the current object.
- [Equals(ResourceCommandSnapshot?)](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/methods.md#equals-resourcecommandsnapshot) : `bool` -- Indicates whether the current object is equal to another object of the same type.
- [GetHashCode](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/methods.md#gethashcode) : `int` -- Serves as the default hash function.
- [op_Equality(ResourceCommandSnapshot?, ResourceCommandSnapshot?)](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/methods.md#op-equality-resourcecommandsnapshot-resourcecommandsnapshot) : `bool` `static`
- [op_Inequality(ResourceCommandSnapshot?, ResourceCommandSnapshot?)](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/methods.md#op-inequality-resourcecommandsnapshot-resourcecommandsnapshot) : `bool` `static`
- [ToString](/reference/api/csharp/aspire.hosting/resourcecommandsnapshot/methods.md#tostring) : `string` -- Returns a string that represents the current object.
