using System;

namespace ZionSchematics.Models.SearchRelationTypes
{
    [Serializable]
    public class SearchRelationFactory
    {
        private const string Above = "ABOVE";
        private const string Below = "BELOW";
        private const string LeftOf = "LEFTOF";
        private const string RightOf = "RIGHTOF";

        public static IRelation Construct(string type)
        {
            switch (type.ToUpper())
            {
                case Above: return new Above();
                case Below: return new Below();
                case LeftOf: return new LeftOf();
                case RightOf: return new RightOf();
                default: return null;
            }
        }

    }
}
