public void read(EndianBinaryReader r)
 {
     if (r.BaseStream.Length > 0)
     {
         Count = r.ReadInt32();
         Phrases = new Phrase[Count]; for (int i = 0; i < Count; i++) { var obj = new Phrase(); obj.read(r); Phrases[i] = obj; }
     }
 }
        private void parsePhrases(Song2014 xml, Sng2014File sng)
        {
            sng.Phrases = new PhraseSection();
            sng.Phrases.Count = xml.Phrases.Length;
            sng.Phrases.Phrases = new Phrase[sng.Phrases.Count];

            for (int i = 0; i < sng.Phrases.Count; i++)
            {
                var phrase = xml.Phrases[i];
                var p = new Phrase();
                p.Solo = phrase.Solo;
                p.Disparity = phrase.Disparity;
                p.Ignore = phrase.Ignore;
                p.MaxDifficulty = phrase.MaxDifficulty;
                p.PhraseIterationLinks = xml.PhraseIterations.Count(iter => iter.PhraseId == i);
                readString(phrase.Name, p.Name);

                sng.Phrases.Phrases[i] = p;
            }
        }
 public void read(BinaryReader r)
 {
     this.Count = r.ReadInt32();
     this.Phrases = new Phrase[this.Count]; for (int i=0; i<this.Count; i++) { Phrase obj = new Phrase(); obj.read(r); this.Phrases[i] = obj; }
 }