Ejemplo n.º 1
0
        public iCalendarCollection ParseStream(TextReader reader) {
            iCalSimpleParser sParser = new iCalSimpleParser();
            sParser.ComponentStart += this.ComponentStartHandler;
            sParser.ComponentEnd += this.ComponentEndHandler;
            sParser.Property += this.PropertyHandler;

            this.Collection = new iCalendarCollection();
            this.Current = this.Collection;
            this.Parent = null;

            this.factory = new iCalComponentFactory();

            sParser.ParseStream( reader );

            return this.Collection;
        }
Ejemplo n.º 2
0
        public iCalendarCollection ParseFile( String filename )
        {
            iCalSimpleParser sParser = new iCalSimpleParser();
            sParser.ComponentStart += this.ComponentStartHandler;
            sParser.ComponentEnd += this.ComponentEndHandler;
            sParser.Property += this.PropertyHandler;

            this.Collection = new iCalendarCollection();
            this.Current = this.Collection;
            this.Parent = null;

            this.factory = new iCalComponentFactory();

            sParser.ParseFile( filename );

            return this.Collection;
        }