public interface IFeature
{
string FeatureName { get; set; }
}
public interface IFeatureRegistry
{
IEnumerable<IFeature> Features { get; set; }
bool IsEnabled(IEnumerable<string> featurePath);
}
public interface IApplicationTenant
{
string ApplicationName { get; }
IFeatureRegistry EnabledFeatures { get; }
}
public abstract class AbstractApplicationTenant : IApplicationTenant
{
public string ApplicationName { get; protected set; }
public IFeatureRegistry EnabledFeatures { get; protected set; }
}
public class SampleTenant : AbstractApplicationTenant
{
public SampleTenant()
{
ApplicationName = "Sample 1";
EnabledFeatures = null;
}
}
Ich bin neu in diesem Bereich. Meine Frage ist, wie man EnabledFeatures
Werte zuweisen?Dependency Injection. Zuweisen von Werten zu IENUMERABLE
Dank Jeco
Bitte formatieren Sie zumindest Ihren Code. –
Ich habe es für ihn getan. (Er ist neu) – Aren