/// <summary>
        /// Applies the rule.
        /// </summary>
        /// <param name="node">The node instance to modify.</param>
        /// <param name="data">Private data from CheckConsistency().</param>
        public override void Apply(IPrecursorIndexAssignmentInstruction node, object data)
        {
            node.LocalScope.Seal();
            node.FullScope.Merge(node.LocalScope);

            ScopeHolder.RecursiveAdd(node.FullScope, node.InnerScopes);

            IList <IScopeHolder> EmbeddingScopeList = ScopeHolder.EmbeddingScope(node);

            EmbeddingScopeList.Add(node);
        }
Exemple #2
0
        /// <summary>
        /// Applies the rule.
        /// </summary>
        /// <param name="node">The node instance to modify.</param>
        /// <param name="data">Private data from CheckConsistency().</param>
        public override void Apply(IAttachment node, object data)
        {
            node.LocalScope.Seal();
            node.FullScope.Merge(node.LocalScope);

            ScopeHolder.RecursiveAdd(node.FullScope, node.InnerScopes);

            IList <IScopeHolder> EmbeddingScopeList = ScopeHolder.EmbeddingScope(node);

            EmbeddingScopeList.Add(node);
        }
Exemple #3
0
        /// <summary>
        /// Applies the rule.
        /// </summary>
        /// <param name="node">The node instance to modify.</param>
        /// <param name="data">Private data from CheckConsistency().</param>
        public override void Apply(IScope node, object data)
        {
            ISealableDictionary <string, IScopeAttributeFeature> CheckedScope = (ISealableDictionary <string, IScopeAttributeFeature>)data;

            node.LocalScope.Merge(CheckedScope);
            node.LocalScope.Seal();
            node.FullScope.Merge(node.LocalScope);

            ScopeHolder.RecursiveAdd(node.FullScope, node.InnerScopes);

            IList <IScopeHolder> EmbeddingScopeList = ScopeHolder.EmbeddingScope(node);

            EmbeddingScopeList.Add(node);
        }
Exemple #4
0
        /// <summary>
        /// Applies the rule.
        /// </summary>
        /// <param name="node">The node instance to modify.</param>
        /// <param name="data">Private data from CheckConsistency().</param>
        public override void Apply(IAttachmentInstruction node, object data)
        {
            IList <ISealableDictionary <string, IScopeAttributeFeature> > CheckedScopeList = (IList <ISealableDictionary <string, IScopeAttributeFeature> >)data;

            Debug.Assert(CheckedScopeList.Count == node.AttachmentList.Count);

            node.LocalScope.Seal();

            for (int i = 0; i < node.AttachmentList.Count; i++)
            {
                IAttachment AttachmentItem = node.AttachmentList[i];
                ISealableDictionary <string, IScopeAttributeFeature> CheckedScope = CheckedScopeList[i];
                AttachmentItem.FullScope.Merge(CheckedScope);
                ScopeHolder.RecursiveAdd(CheckedScope, AttachmentItem.InnerScopes);
            }

            IList <IScopeHolder> EmbeddingScopeList = ScopeHolder.EmbeddingScope(node);

            EmbeddingScopeList.Add(node);
        }