1 write to _context
System.Data.Entity (1)
System\Data\Mapping\ViewGeneration\QueryRewriting\QueryRewriter.cs (1)
82_context = context;
47 references to _context
System.Data.Entity (47)
System\Data\Mapping\ViewGeneration\QueryRewriting\QueryRewriter.cs (47)
92foreach (LeftCellWrapper leftCellWrapper in _context.AllWrappersForExtent) 136if (_context.ViewTarget == ViewTarget.QueryView) 147_context.MemberMaps.ProjectedSlotMap, _usedCells, 148_domainQuery, _context, _domainMap, _errorLog, _config); 153bool noWhereClauseNeeded = _context.LeftFragmentQP.IsContainedIn(_basicView.LeftFragmentQuery, _domainQuery); 171get { return _context; } 209if (_context.ViewTarget == ViewTarget.QueryView && MemberPath.EqualityComparer.Equals(currentPath, _extentPath)) 221types = MetadataHelper.GetTypeAndSubtypesOf(_generatedType, _context.EdmItemCollection, false /* don't include abstract types */); 238switch (_context.ViewTarget) 279CellTreeNode cellTree = TileToCellTree((Tile<FragmentQuery>)caseRewriting, _context); 302if (_context.ViewTarget == ViewTarget.QueryView) 322derivedTypes = MetadataHelper.GetTypeAndSubtypesOf(generatedType, _context.EdmItemCollection, false /* don't include abstract types */); 408if (!ErrorPatternMatcher.FindMappingErrors(_context, _domainMap, _errorLog)) 425ErrorLog.Record record = new ErrorLog.Record(true, ViewGenErrorCode.AmbiguousMultiConstants, builder.ToString(), _context.AllWrappersForExtent, String.Empty); 488ErrorLog.Record record = new ErrorLog.Record(true, ViewGenErrorCode.AttributesUnrecoverable, builder.ToString(), _context.AllWrappersForExtent, String.Empty); 498IEnumerable<LeftCellWrapper> usedCells = _context.AllWrappersForExtent.Where(w => _usedViews.Contains(w.FragmentQuery)); 500_context, CellTreeOpType.Union, 501usedCells.Select(wrapper => new LeafCellTreeNode(_context, wrapper)).ToArray()); 522if (domainValue == Constant.Undefined && _context.ViewTarget == ViewTarget.QueryView) 538if (_context.ViewTarget == ViewTarget.UpdateView) 556Debug.Assert(_context.ViewTarget == ViewTarget.UpdateView || !_config.IsValidationEnabled); 559if (!ErrorPatternMatcher.FindMappingErrors(_context, _domainMap, _errorLog)) 563string objectString = _context.ViewTarget == ViewTarget.QueryView ? 566if (_context.ViewTarget == ViewTarget.QueryView) 574RewritingValidator.EntityConfigurationToUserString(memberConditionQuery.Condition, builder, _context.ViewTarget == ViewTarget.UpdateView); 575ErrorLog.Record record = new ErrorLog.Record(true, ViewGenErrorCode.AmbiguousMultiConstants, builder.ToString(), _context.AllWrappersForExtent, String.Empty); 587if (_context.ViewTarget == ViewTarget.UpdateView && needCaseStatement) 604Debug.Assert(_context.ViewTarget == ViewTarget.UpdateView, "Used for update views only"); 612CellTreeNode unionTree = TileToCellTree(unionCaseRewriting, _context); 613FragmentQuery configurationNeedsDefault = _context.RightFragmentQP.Difference(rightDomainQuery.RightFragmentQuery, unionTree.RightFragmentQuery); 615if (_context.RightFragmentQP.IsSatisfiable(configurationNeedsDefault)) 627_errorLog.AddEntry(new ErrorLog.Record(true, ViewGenErrorCode.NoDefaultValue, builder.ToString(), _context.AllWrappersForExtent, String.Empty)); 637if (_context.ViewTarget == ViewTarget.QueryView) 661if (_context.ViewTarget == ViewTarget.QueryView && _config.IsValidationEnabled) 678foreach (MemberPath memberPath in _context.MemberMaps.ProjectedSlotMap.Members) 688foreach (LeftCellWrapper leftCellWrapper in _context.AllWrappersForExtent) 720LeftCellWrapper fragment = _context.AllWrappersForExtent.First(lcr => lcr.FragmentQuery.Equals(toFill.Query)); 744foreach (LeftCellWrapper leftCellWrapper in _context.AllWrappersForExtent) 783for (int memberNum = 0; memberNum < _context.MemberMaps.ProjectedSlotMap.Count; memberNum++) 785MemberPath memberPath = _context.MemberMaps.ProjectedSlotMap[memberNum]; 834bool isRelaxed = (_context.ViewTarget == ViewTarget.UpdateView); 847if (_context.TryGetCachedRewriting(toFillQuery, out rewriting)) 891_context.SetCachedRewriting(originalToFillQuery, rewriting); 912_context.SetCachedRewriting(originalToFillQuery, rewriting); 926if (!_context.TryGetCachedRewriting(toFill.Query, out rewriting)) 932_context.SetCachedRewriting(toFill.Query, rewriting); 1263return !_context.LeftFragmentQP.IsSatisfiable(FragmentQuery.Create(BoolExpression.CreateNot(query.Condition)));