Esempio n. 1
0
    public FormView(
        object obj)
    {
        if (obj == null)
        {
            throw new ArgumentNullException("obj");
        }
        var type    = obj.GetType();
        var builder = FormLoader.Get(type);

        if (builder == null)
        {
            var message = string.Format("Unable to find form builder for type: {0}", type.FullName);
            throw new InvalidOperationException(message);
        }
        Actions = GetActions(builder);
        Groups  = GetGroups(obj, builder);
    }