Beispiel #1
0
        public void Add(IInstruction instruction, IInstructionSubject subject)
        {
            if (instruction == null)
            {
                throw new ArgumentNullException("instruction");
            }
            if (subject == null)
            {
                throw new ArgumentNullException("subject");
            }

            _points.Add(new Point
            {
                Instruction = instruction,
                Subject     = subject
            });
        }
Beispiel #2
0
        public void Add(ISehTryBlock tryBlock, IInstructionSubject from, IInstructionSubject to)
        {
            if (tryBlock == null)
            {
                throw new ArgumentNullException("tryBlock");
            }
            if (from == null && to == null)
            {
                throw new ArgumentNullException("from");
            }

            _blocks.Add(new Block
            {
                Try  = tryBlock,
                From = from,
                To   = to
            });
        }