AI-Studio/app/MindWork AI Studio/Tools/EncryptedText.cs

13 lines
364 B
C#
Raw Normal View History

using System.Security;
namespace AIStudio.Tools;
public readonly record struct EncryptedText(string EncryptedData)
{
public EncryptedText() : this(string.Empty)
{
throw new SecurityException("Please provide the encrypted data.");
}
public static implicit operator string(EncryptedText encryptedText) => encryptedText.EncryptedData;
}