6 instantiations of ResourceJson
aspire (1)
Backchannel\ResourceSnapshotMapper.cs (1)
117
return new
ResourceJson
Aspire.Cli.Tests (5)
Commands\DescribeCommandTests.cs (5)
194
new
ResourceJson
{ Name = "frontend", DisplayName = "frontend", ResourceType = "Project", State = "Running" },
195
new
ResourceJson
{ Name = "postgres", DisplayName = "postgres", ResourceType = "Container", State = "Running" },
196
new
ResourceJson
{ Name = "redis", DisplayName = "redis", ResourceType = "Container", State = "Starting" }
236
new
ResourceJson
{ Name = "frontend", DisplayName = "frontend", ResourceType = "Project", State = "Running" },
237
new
ResourceJson
{ Name = "postgres", DisplayName = "postgres", ResourceType = "Container", State = "Running" }
18 references to ResourceJson
aspire (12)
Backchannel\ResourceSnapshotMapper.cs (5)
12
/// Maps <see cref="ResourceSnapshot"/> to <see cref="
ResourceJson
"/> for serialization.
17
/// Maps a list of <see cref="ResourceSnapshot"/> to a list of <see cref="
ResourceJson
"/>.
22
public static List<
ResourceJson
> MapToResourceJsonList(IEnumerable<ResourceSnapshot> snapshots, string? dashboardBaseUrl = null, bool includeEnvironmentVariableValues = true)
29
/// Maps a <see cref="ResourceSnapshot"/> to <see cref="
ResourceJson
"/>.
35
public static
ResourceJson
MapToResourceJson(ResourceSnapshot snapshot, IReadOnlyList<ResourceSnapshot> allSnapshots, string? dashboardBaseUrl = null, bool includeEnvironmentVariableValues = true)
Commands\DescribeCommand.cs (3)
25
public required
ResourceJson
[] Resources { get; init; }
29
[JsonSerializable(typeof(
ResourceJson
))]
229
var
resourceJson = ResourceSnapshotMapper.MapToResourceJson(snapshot, currentSnapshots, dashboardBaseUrl);
Commands\PsCommand.cs (3)
32
public List<
ResourceJson
>? Resources { get; set; }
36
[JsonSerializable(typeof(
ResourceJson
))]
173
List<
ResourceJson
>? resources = null;
Mcp\Tools\ListResourcesTool.cs (1)
15
[JsonSerializable(typeof(
ResourceJson
[]))]
Aspire.Cli.Tests (6)
Backchannel\ResourceSnapshotMapperTests.cs (1)
39
var
result = ResourceSnapshotMapper.MapToResourceJson(snapshot, allSnapshots, dashboardBaseUrl: "http://localhost:18080");
Commands\DescribeCommandTests.cs (3)
212
var
deserialized = JsonSerializer.Deserialize(line, ResourcesCommandJsonContext.Ndjson.ResourceJson);
287
var
first = JsonSerializer.Deserialize(jsonLines[0], ResourcesCommandJsonContext.Ndjson.ResourceJson);
293
var
second = JsonSerializer.Deserialize(jsonLines[1], ResourcesCommandJsonContext.Ndjson.ResourceJson);
Commands\PsCommandTests.cs (2)
262
var
apiService = appHost.Resources.First(r => r.Name == "apiservice");
269
var
redis = appHost.Resources.First(r => r.Name == "redis");