using System;
namespace Kreta.Framework.Entities
{
///
/// Entitás DictionaryItem tulajdonságait leíró attribútum.
///
[AttributeUsage(AttributeTargets.Property, Inherited = true, AllowMultiple = true)]
public sealed class EntityDictionaryItemPropertyAttribute : Attribute
{
private string m_DictionaryItemFieldName;
private string m_DictionaryItemClassName;
private Type m_DictionaryItemClassType;
///
/// Az attributum konstruktora
///
/// A dictitem mező neve
/// A dictitem osztály neve
/// A dictitem osztály típusa
public EntityDictionaryItemPropertyAttribute(string dictionaryItemFieldName, string dictionaryItemClassName, Type dictionaryItemClassType)
{
m_DictionaryItemClassName = dictionaryItemClassName;
m_DictionaryItemFieldName = dictionaryItemFieldName;
m_DictionaryItemClassType = dictionaryItemClassType;
}
///
/// Az attributum konstruktora
///
/// A dictitem mező neve
/// A dictitem osztály neve
public EntityDictionaryItemPropertyAttribute(string dictionaryItemFieldName, string dictionaryItemClassName)
{
m_DictionaryItemClassName = dictionaryItemClassName;
m_DictionaryItemFieldName = dictionaryItemFieldName;
m_DictionaryItemClassType = null;
}
public string DictionaryItemFieldName
{
get
{
return m_DictionaryItemFieldName;
}
}
public string DictionaryItemClassName
{
get
{
return m_DictionaryItemClassName;
}
}
public Type DictionaryItemClassType
{
get
{
return m_DictionaryItemClassType;
}
}
}
}