pixelgon/Assets/NaughtyAttributes/Scripts/Editor/CodeGeneration/PropertyMetaDatabase.cs
2020-06-05 11:54:36 -07:00

34 lines
899 B
C#

// This class is auto generated
using System;
using System.Collections.Generic;
namespace NaughtyAttributes.Editor
{
public static class PropertyMetaDatabase
{
private static Dictionary<Type, PropertyMeta> metasByAttributeType;
static PropertyMetaDatabase()
{
metasByAttributeType = new Dictionary<Type, PropertyMeta>();
metasByAttributeType[typeof(InfoBoxAttribute)] = new InfoBoxPropertyMeta();
metasByAttributeType[typeof(OnValueChangedAttribute)] = new OnValueChangedPropertyMeta();
}
public static PropertyMeta GetMetaForAttribute(Type attributeType)
{
PropertyMeta meta;
if (metasByAttributeType.TryGetValue(attributeType, out meta))
{
return meta;
}
else
{
return null;
}
}
}
}