Exemple #1
0
 /// <summary>
 /// Ctor
 /// </summary>
 public CR01()
 {
     this.m_handler = new PixHandler()
     {
         Context = this
     };
 }
Exemple #2
0
        private PixHandler GetHandlersChain()
        {
            PixHandler handler = this.Handlers.Aggregate((cur, next) =>
            {
                cur.SetNext(next);
                return(next);
            });

            // DeskewHandler deskewHandler = new DeskewHandler();
            // GrayscaleHandler grayscaleHandler = new GrayscaleHandler();
            // RemoveLinesHandler removeLinesHandler = new RemoveLinesHandler();
            // deskewHandler.SetNext(grayscaleHandler);
            // grayscaleHandler.SetNext(removeLinesHandler);
            //
            // return deskewHandler;
            return(handler);
        }
 public void AddHandler(PixHandler handler)
 {
     handler.Id = _idSequence++;
     this.Handlers.Add(handler);
 }