port from perforce
This commit is contained in:
34
intromat/Intromat/Nodes/Code/LiteralModelBase.cs
Normal file
34
intromat/Intromat/Nodes/Code/LiteralModelBase.cs
Normal file
@@ -0,0 +1,34 @@
|
||||
using System.Xml.Serialization;
|
||||
using Intromat.Nodes.Textures;
|
||||
using Intromat.PersistentModel;
|
||||
|
||||
namespace Intromat.Nodes.Code
|
||||
{
|
||||
public enum ERelativeSource
|
||||
{
|
||||
Custom,
|
||||
Parent,
|
||||
Input
|
||||
}
|
||||
|
||||
[XmlInclude(typeof(IntLiteralModel))]
|
||||
[XmlInclude(typeof(StringLiteralModel))]
|
||||
[XmlInclude(typeof(FloatLiteralModel))]
|
||||
[XmlInclude(typeof(BooleanLiteralModel))]
|
||||
[XmlInclude(typeof(SamplerLiteralModel))]
|
||||
public abstract class LiteralModelBase : NodeModelBase
|
||||
{
|
||||
public ERelativeSource RelativeSource { get; set; }
|
||||
}
|
||||
|
||||
public class LiteralModelEntry
|
||||
{
|
||||
public string Key { get; set; } = null!;
|
||||
public LiteralModelBase Literal { get; set; } = null!;
|
||||
}
|
||||
|
||||
public abstract class LiteralModelBase<T> : LiteralModelBase
|
||||
{
|
||||
public T Value { get; set; } = default!;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user