Exemplo n.º 1
0
        public static CalendarCollection Load(TextReader tr)
        {
            var calendars  = SimpleDeserializer.Default.Deserialize(tr).OfType <Calendar>();
            var collection = new CalendarCollection();

            collection.AddRange(calendars);
            return(collection);
        }
Exemplo n.º 2
0
 protected bool Equals(CalendarCollection obj) => CollectionHelpers.Equals(this, obj);
Exemplo n.º 3
0
 public static Calendar Load(TextReader tr)
 => CalendarCollection.Load(tr).OfType <Calendar>().SingleOrDefault();
Exemplo n.º 4
0
 /// <summary>
 /// Loads an <see cref="Calendar"/> from an open stream.
 /// </summary>
 /// <param name="s">The stream from which to load the <see cref="Calendar"/> object</param>
 /// <returns>An <see cref="Calendar"/> object</returns>
 public static Calendar Load(Stream s)
 => CalendarCollection.Load(new StreamReader(s, Encoding.UTF8)).SingleOrDefault();
Exemplo n.º 5
0
 public static Calendar Load(string iCalendarString, bool collectErrors)
 => CalendarCollection.Load(new StringReader(iCalendarString), collectErrors).SingleOrDefault();
Exemplo n.º 6
0
 public static Calendar Load(string iCalendarString)
 => CalendarCollection.Load(new StringReader(iCalendarString)).SingleOrDefault();
Exemplo n.º 7
0
 protected bool Equals(CalendarCollection obj)
 {
     return(this.SequenceEqual(obj));
 }