private Type ObtainRootType(RequestContext context, string target, out string[] pieces) { pieces = target.Split(new char[] { '.' }); Type foundType = (Type) Controller.PropertyBag[pieces[0] + "type"]; if (foundType == null) { object root = ObtainRootInstance(context, target, out pieces); if (root != null) { foundType = root.GetType(); } } return foundType; }