/// <summary> /// Create proxy from the specified document and entity type. /// </summary> /// <param name="doc"></param> /// <param name="entityType"></param> /// <returns></returns> public object CreateProxy( JToken doc, Type entityType, string id, PreProcessInfo preProcess, OdmViewProcessingOptions processingOptions, bool emptyProxy) { EntityDefinition entityDef = context.Mapping.GetEntityDefinition(entityType); object proxy = entityDef.CreateInstance(); FillProxy(entityDef, proxy, doc, id, preProcess, processingOptions, emptyProxy); return(proxy); }