コード例 #1
0
        internal protected virtual void AssignExcludingRedirects(FtMetaSequence source, FtMetaFieldList fieldList, FtMetaFieldList sourceFieldList)
        {
            Name = source.Name;
            root = source.Root;

            itemList.AssignExcludingRedirects(source.itemList, fieldList, sourceFieldList);
        }
コード例 #2
0
        public FtMetaSequence New()
        {
            FtMetaSequence result = SequenceFactory.CreateMetaSequence();

            Add(result);
            return(result);
        }
コード例 #3
0
        internal FtMetaSequence CreateCopyExcludingRedirects(FtMetaFieldList fieldList, FtMetaFieldList sourceFieldList)
        {
            FtMetaSequence sequence = SequenceFactory.CreateMetaSequence();

            sequence.AssignExcludingRedirects(this, fieldList, sourceFieldList);
            return(sequence);
        }
コード例 #4
0
        public void Remove(FtMetaSequence sequence)
        {
            int idx = list.IndexOf(sequence);

            if (idx >= 0)
            {
                RemoveAt(idx);
            }
        }
コード例 #5
0
 private void HandleSequenceRootedEvent(FtMetaSequence rootedSequence)
 {
     foreach (FtMetaSequence sequence in list)
     {
         if ((sequence != rootedSequence) && sequence.Root)
         {
             sequence.Root = false;
         }
     }
 }
コード例 #6
0
        public int IndexOfName(string name)
        {
            int result = -1;

            for (int i = 0; i < Count; i++)
            {
                if (FtMetaSequence.SameName(list[i].Name, name))
                {
                    result = i;
                    break;
                }
            }

            return(result);
        }
コード例 #7
0
        internal void Assign(FtMetaSequenceList source, FtMetaFieldList fieldList, FtMetaFieldList sourceFieldList)
        {
            list.Clear();
            list.Capacity = source.Count;

            for (int i = 0; i < source.Count; i++)
            {
                FtMetaSequence sequence = source[i].CreateCopyExcludingRedirects(fieldList, sourceFieldList);
                Add(sequence);
            }

            // All Sequences need to be created before we can assign Redirects

            for (int i = 0; i < Count; i++)
            {
                list[i].AssignRedirects(this, source);
            }
        }
コード例 #8
0
 private void Add(FtMetaSequence sequence)
 {
     list.Add(sequence);
     BindSequenceEvents(sequence);
 }
コード例 #9
0
 private void UnbindSequenceEvents(FtMetaSequence sequence)
 {
     sequence.RootedEvent -= HandleSequenceRootedEvent;
 }
コード例 #10
0
 public int IndexOf(FtMetaSequence sequence)
 {
     return(list.IndexOf(sequence));
 }