divan/RMuseum/Services/Implementation/DiwanPoemFormatConvertor.cs
Anas Rashid e8f2306422 Rename Ganjoor -> Diwan throughout the code
Projects (GanjooRazor -> DiwanRazor, GanjoorService.sln -> DiwanService.sln), files,
folders, classes, namespaces, settings, API routes (/api/diwan) and DB tables (Diwan*).
External addresses (ganjoor.net, github.com/ganjoor) unchanged. Migrations renamed
consistently (no pending model changes); requires a fresh database.
Upstream RUNNING_LOCALLY/SEMANTIC_SEARCH docs archived unmodified under docs/.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-04 23:49:01 +02:00

75 lines
2.8 KiB
C#

using RMuseum.Models.Diwan;
namespace RMuseum.Services.Implementation
{
/// <summary>
/// poem format convertor
/// </summary>
public static class DiwanPoemFormatConvertor
{
/// <summary>
/// تبدیل به رشته
/// </summary>
/// <param name="format"></param>
/// <returns></returns>
public static string GetString(DiwanPoemFormat? format)
{
if (format == null) return "";
switch (format)
{
case DiwanPoemFormat.Ghazal:
return "غزل";
case DiwanPoemFormat.Ghaside:
return "قصیده";
case DiwanPoemFormat.Masnavi:
return "مثنوی";
case DiwanPoemFormat.Ghete:
return "قطعه";
case DiwanPoemFormat.Robaee:
return "رباعی";
case DiwanPoemFormat.Dobeyti:
return "دوبیتی";
case DiwanPoemFormat.Generic:
return "غزل/قصیده/قطعه";
case DiwanPoemFormat.TarkibBand:
return "ترکیب بند";
case DiwanPoemFormat.Takbeyt:
return "تک بیت";
case DiwanPoemFormat.Nimaee:
return "نیمایی";
case DiwanPoemFormat.TarjeeBand:
return "ترجیع بند";
case DiwanPoemFormat.Mosammat3:
return "مسمط مثلث";
case DiwanPoemFormat.Mostazad:
return "مستزاد";
case DiwanPoemFormat.RobaeeMostazad:
return "رباعی مستزاد";
case DiwanPoemFormat.Mosammat4:
return "مسمط مربع";
case DiwanPoemFormat.Mosammat5:
return "مسمط مخمس";
case DiwanPoemFormat.Sepeed:
return "سپید";
case DiwanPoemFormat.New:
return "نیمایی یا سپید";
case DiwanPoemFormat.Mosammat6:
return "مسمط مسدس";
case DiwanPoemFormat.Mosammat8:
return "مسمط مثمن";
case DiwanPoemFormat.Mosammat:
return "مسمط";
case DiwanPoemFormat.ChaharPare:
return "چهارپاره";
case DiwanPoemFormat.MultiBand:
return "چند بندی";
case DiwanPoemFormat.BahreTavil:
return "بحر طویل";
case DiwanPoemFormat.Unknown:
return "نامشخص";
}
return "";
}
}
}