// ========================================================================== // Squidex Headless CMS // ========================================================================== // Copyright (c) Squidex UG (haftungsbeschränkt) // All rights reserved. Licensed under the MIT license. // ========================================================================== using System; using Squidex.Domain.Apps.Core; using Squidex.Domain.Apps.Core.Assets; using Squidex.Infrastructure; namespace Squidex.Domain.Apps.Entities.Contents.TestData { public sealed class FakeUrlGenerator : IUrlGenerator { public bool CanGenerateAssetSourceUrl { get; } = true; public string? AssetThumbnail(Guid assetId, AssetType assetType) { return $"assets/{assetId}?width=100"; } public string? AssetSource(Guid assetId, long fileVersion) { return $"assets/source/{assetId}"; } public string AssetContent(Guid assetId) { return $"assets/{assetId}"; } public string ContentUI(NamedId appId, NamedId schemaId, Guid contentId) { return $"contents/{schemaId.Name}/{contentId}"; } public string AppSettingsUI(NamedId appId) { throw new NotSupportedException(); } public string AssetsUI(NamedId appId) { throw new NotSupportedException(); } public string AssetsUI(NamedId appId, string? query = null) { throw new NotSupportedException(); } public string AssetSource(Guid assetId) { throw new NotSupportedException(); } public string BackupsUI(NamedId appId) { throw new NotSupportedException(); } public string ClientsUI(NamedId appId) { throw new NotSupportedException(); } public string ContentsUI(NamedId appId) { throw new NotSupportedException(); } public string ContentsUI(NamedId appId, NamedId schemaId) { throw new NotSupportedException(); } public string ContributorsUI(NamedId appId) { throw new NotSupportedException(); } public string DashboardUI(NamedId appId) { throw new NotSupportedException(); } public string LanguagesUI(NamedId appId) { throw new NotSupportedException(); } public string PatternsUI(NamedId appId) { throw new NotSupportedException(); } public string PlansUI(NamedId appId) { throw new NotSupportedException(); } public string RolesUI(NamedId appId) { throw new NotSupportedException(); } public string RulesUI(NamedId appId) { throw new NotSupportedException(); } public string SchemasUI(NamedId appId) { throw new NotSupportedException(); } public string SchemaUI(NamedId appId, NamedId schemaId) { throw new NotSupportedException(); } public string WorkflowsUI(NamedId appId) { throw new NotSupportedException(); } public string UI() { throw new NotSupportedException(); } } }