Пример #1
0
 public ChangeAction(ChangeType changeType, TranscriptionElement changedElement, TranscriptionIndex changeIndex, int changeAbsoluteIndex)
 {
     _changeType = changeType;
     _changedElement = changedElement;
     _changeTranscriptionIndex = changeIndex;
     _changeAbsoluteIndex = changeAbsoluteIndex;
 }
Пример #2
0
 public ReplaceAction(TranscriptionElement changedElement, TranscriptionIndex changeIndex, int changeAbsoluteIndex)
     : base(ChangeType.Replace, changedElement, changeIndex, changeAbsoluteIndex)
 {
 }
Пример #3
0
 public BeginAction(TranscriptionElement changedElement, TranscriptionIndex changeIndex, int changeAbsoluteIndex, TimeSpan oldtime)
     : base(ChangeType.Modify, changedElement, changeIndex,changeAbsoluteIndex)
 {
     _oldtime = oldtime;
 }
Пример #4
0
 public PhrasePhoneticsAction(TranscriptionPhrase changedelement, TranscriptionIndex changeIndex, int changeAbsoluteIndex, string oldphonetics)
     : base(ChangeType.Modify, changedelement, changeIndex, changeAbsoluteIndex)
 {
     _oldtstring = oldphonetics;
 }
Пример #5
0
 public abstract void Insert(TranscriptionIndex index, TranscriptionElement value);
Пример #6
0
 public override void Insert(TranscriptionIndex index, TranscriptionElement value)
 {
     throw new NotImplementedException();
 }
Пример #7
0
 public override void RemoveAt(TranscriptionIndex index)
 {
     ValidateIndexOrThrow(index);
     if (index.IsSectionIndex)
     {
         if (index.IsParagraphIndex)
             Sections[index.Sectionindex].RemoveAt(index);
         else
             Sections.RemoveAt(index.ParagraphIndex);
     }
     else
     {
         throw new IndexOutOfRangeException("index");
     }
 }
Пример #8
0
        public override TranscriptionElement this[TranscriptionIndex index]
        {
            get
            {
                ValidateIndexOrThrow(index);

                if (index.IsSectionIndex)
                {
                    if (index.IsParagraphIndex)
                        return Sections[index.Sectionindex][index];

                    return Sections[index.Sectionindex];
                }

                throw new IndexOutOfRangeException("index");
            }
            set
            {
                ValidateIndexOrThrow(index);

                if (index.IsSectionIndex)
                {
                    if (index.IsParagraphIndex)
                        Sections[index.Sectionindex][index] = value;
                    else
                        Sections[index.Sectionindex] = (TranscriptionSection)value;
                }
                else
                    throw new IndexOutOfRangeException("index");

            }
        }
Пример #9
0
        public override void RemoveAt(TranscriptionIndex index)
        {
            ValidateIndexOrThrow(index);
            if (!index.IsPhraseIndex)
                throw new IndexOutOfRangeException("index");

            Phrases.RemoveAt(index.PhraseIndex);
        }
Пример #10
0
        public override void Insert(TranscriptionIndex index, TranscriptionElement value)
        {
            ValidateIndexOrThrow(index);
            if (!index.IsPhraseIndex)
                throw new IndexOutOfRangeException("index");

            Phrases.Insert(index.PhraseIndex,(TranscriptionPhrase)value);
        }
Пример #11
0
        public override TranscriptionElement this[TranscriptionIndex index]
        {
            get
            {
                ValidateIndexOrThrow(index);
                if(!index.IsPhraseIndex)
                    throw new IndexOutOfRangeException("index");
                return Phrases[index.PhraseIndex];
            }
            set
            {
                ValidateIndexOrThrow(index);
                if (!index.IsPhraseIndex)
                    throw new IndexOutOfRangeException("index");

                Phrases[index.PhraseIndex] = (TranscriptionPhrase)value;
            }
        }
Пример #12
0
        public override TranscriptionElement this[TranscriptionIndex index]
        {
            get
            {
                ValidateIndexOrThrow(index);

                if (index.IsParagraphIndex)
                {
                    if (index.IsPhraseIndex)
                        return Paragraphs[index.ParagraphIndex][index];

                    return Paragraphs[index.ParagraphIndex];
                }

                throw new IndexOutOfRangeException("index");
            }
            set
            {
                ValidateIndexOrThrow(index);

                if (index.IsParagraphIndex)
                {
                    if (index.IsPhraseIndex)
                        Paragraphs[index.ParagraphIndex][index] = value;
                    else
                        Paragraphs[index.ParagraphIndex] = (TranscriptionParagraph)value;
                }
                else
                {
                    throw new IndexOutOfRangeException("index");
                }

            }
        }
Пример #13
0
 public void ValidateIndexOrThrow(TranscriptionIndex index)
 {
     if (!index.IsValid)
         throw new ArgumentOutOfRangeException("index", "invalid index value");
 }
Пример #14
0
 public abstract void RemoveAt(TranscriptionIndex index);
Пример #15
0
 public TextAction(TranscriptionElement changedelement, TranscriptionIndex changeIndex, int changeAbsoluteIndex, string oldtstring)
     : base(ChangeType.Modify, changedelement, changeIndex, changeAbsoluteIndex)
 {
     _oldtstring = oldtstring;
 }
Пример #16
0
 public InsertAction(TranscriptionElement changedElement, TranscriptionIndex changeIndex, int changeAbsoluteIndex)
     : base(ChangeType.Add, changedElement, changeIndex, changeAbsoluteIndex)
 {
 }
Пример #17
0
 public ParagraphAttibutesAction(TranscriptionParagraph changedParagraph, TranscriptionIndex changeIndex,int changeAbsoluteIndex, ParagraphAttributes oldAttributes)
     : base(ChangeType.Modify, changedParagraph, changeIndex, changeAbsoluteIndex)
 {
     _oldAttributes = oldAttributes;
 }
Пример #18
0
 public override void Insert(TranscriptionIndex index, TranscriptionElement value)
 {
     ValidateIndexOrThrow(index);
     if (index.IsSectionIndex)
     {
         if (index.IsParagraphIndex)
             Sections[index.Sectionindex].Insert(index, value);
         else
             Sections.Insert(index.Sectionindex,(TranscriptionSection)value);
     }
     else
     {
         throw new IndexOutOfRangeException("index");
     }
 }
Пример #19
0
 public ParagraphLanguageAction(TranscriptionParagraph changedParagraph, TranscriptionIndex changeIndex, int changeAbsoluteIndex, string oldLanguage)
     : base(ChangeType.Modify, changedParagraph, changeIndex, changeAbsoluteIndex)
 {
     _oldLanguage = oldLanguage;
 }
Пример #20
0
 public override TranscriptionElement this[TranscriptionIndex index]
 {
     get
     {
         throw new NotImplementedException();
     }
     set
     {
         throw new NotImplementedException();
     }
 }
Пример #21
0
 public ParagraphSpeakerAction(TranscriptionParagraph changedParagraph, TranscriptionIndex changeIndex,int changeAbsoluteIndex, Speaker oldSpeaker)
     : base(ChangeType.Modify, changedParagraph, changeIndex, changeAbsoluteIndex)
 {
     _oldSpeaker = oldSpeaker;
 }
Пример #22
0
 public override void RemoveAt(TranscriptionIndex index)
 {
     throw new NotImplementedException();
 }
Пример #23
0
 public abstract TranscriptionElement this[TranscriptionIndex index]
 {
     get;
     set;
 }