43 references to EndpointProperty
Aspire.Hosting (43)
ApplicationModel\EndpointReference.cs (22)
49internal string GetExpression(EndpointProperty property = EndpointProperty.Url) 53EndpointProperty.Url => "url", 54EndpointProperty.Host or EndpointProperty.IPV4Host => "host", 55EndpointProperty.Port => "port", 56EndpointProperty.Scheme => "scheme", 57EndpointProperty.TargetPort => "targetPort", 67/// <param name="property">The <see cref="EndpointProperty"/> enum value to use in the reference.</param> 68/// <returns>An <see cref="EndpointReferenceExpression"/> representing the specified <see cref="EndpointProperty"/>.</returns> 69public EndpointReferenceExpression Property(EndpointProperty property) 148public class EndpointReferenceExpression(EndpointReference endpointReference, EndpointProperty property) : IManifestExpressionProvider, IValueProvider, IValueWithReferences 156/// Gets the <see cref="EndpointProperty"/> for the property expression. 158public EndpointProperty Property { get; } = property; 170/// <returns>A <see cref="string"/> containing the selected <see cref="EndpointProperty"/> value.</returns> 171/// <exception cref="InvalidOperationException">Throws when the selected <see cref="EndpointProperty"/> enumeration is not known.</exception> 174EndpointProperty.Url => new(Endpoint.Url), 175EndpointProperty.Host => new(Endpoint.Host), 176EndpointProperty.IPV4Host => new("127.0.0.1"), 177EndpointProperty.Port => new(Endpoint.Port.ToString(CultureInfo.InvariantCulture)), 178EndpointProperty.Scheme => new(Endpoint.Scheme), 179EndpointProperty.TargetPort => new(ComputeTargetPort()),
ApplicationModel\ExpressionResolver.cs (15)
25async Task<string?> EvalEndpointAsync(EndpointReference endpointReference, EndpointProperty property) 39if (property is EndpointProperty.Host or EndpointProperty.IPV4Host) 43else if (property == EndpointProperty.Port) 47else if (property == EndpointProperty.Url) 68(EndpointProperty.Host or EndpointProperty.IPV4Host, true, true) => target.Name, 69(EndpointProperty.Port, true, true) => await endpointReference.Property(EndpointProperty.TargetPort).GetValueAsync(cancellationToken).ConfigureAwait(false), 71(EndpointProperty.Host or EndpointProperty.IPV4Host, false, _) => containerHostName, 72(EndpointProperty.Url, _, _) => string.Format(CultureInfo.InvariantCulture, "{0}://{1}:{2}", 74await EvalEndpointAsync(endpointReference, EndpointProperty.Host).ConfigureAwait(false), 75await EvalEndpointAsync(endpointReference, EndpointProperty.Port).ConfigureAwait(false)), 145EndpointReference endpointReference => await EvalEndpointAsync(endpointReference, EndpointProperty.Url).ConfigureAwait(false),
ProjectResourceBuilderExtensions.cs (5)
671context.EnvironmentVariables["ASPNETCORE_HTTPS_PORT"] = e.Property(EndpointProperty.Port); 679aspnetCoreUrls.Append($"{e.Property(EndpointProperty.Scheme)}://{targetHost}:{e.Property(EndpointProperty.TargetPort)}"); 724ports.Append($"{e.Property(EndpointProperty.TargetPort)}"); 756var url = ReferenceExpression.Create($"{e.EndpointAnnotation.UriScheme}://{host}:{e.Property(EndpointProperty.TargetPort)}");
ResourceBuilderExtensions.cs (1)
544context.EnvironmentVariables[env] = endpointReference.Property(EndpointProperty.TargetPort);