Exemplo n.º 1
0
        private string typeFrom(TemplateType templateType)
        {
            var result = new List <string>();

            allPrimitiveTypes().Where(pt => templateType.Is(pt)).Each(t => result.Add(t.ToString()));
            return(result.ToString(",", "'"));
        }
        private bool shouldLoadTemplateWithReferences(TemplateType templateType)
        {
            if (!selectionSupportsReference(templateType))
            {
                return(false);
            }

            //For simulation subject always save linked expression profiles
            if (templateType.Is(TemplateType.SimulationSubject))
            {
                return(true);
            }

            var message = getMessageForLoadWithReference(templateType);

            return(_dialogCreator.MessageBoxYesNo(message) == ViewResult.Yes);
        }
Exemplo n.º 3
0
 public static bool SupportsReference(this TemplateType templateType) =>
 templateType.Is(TemplateType.Individual) ||
 templateType.Is(TemplateType.Population) ||
 templateType.Is(TemplateType.Compound);