Ejemplo n.º 1
0
        protected Exception CreateException(string message, Token token)
        {
            string msg;

            msg = String.Format(message, null, token.Line + 1, token.Pos + 1);

            ValidatorException ex = new ValidatorException(msg);
            ex.Token = token;

            return ex;
        }
Ejemplo n.º 2
0
        protected Exception CreateException(string message, Token token)
        {
            string msg;

            msg = String.Format(message, null, token.Line + 1, token.Pos + 1);

            ValidatorException ex = new ValidatorException(msg);

            ex.Token = token;

            return(ex);
        }
Ejemplo n.º 3
0
        protected Exception CreateException(string message, Exception innerException, string objectName, Node node)
        {
            string msg;
            Token t = null;

            if (node != null)
            {
                msg = String.Format(message, objectName, node.Line + 1, node.Col + 1);
            }
            else
            {
                msg = String.Format(message, objectName);
            }

            ValidatorException ex = new ValidatorException(msg, innerException);
            ex.Token = t;

            return ex;
        }
Ejemplo n.º 4
0
        protected Exception CreateException(string message, Exception innerException, string objectName, Node node)
        {
            string msg;
            Token  t = null;

            if (node != null)
            {
                msg = String.Format(message, objectName, node.Line + 1, node.Col + 1);
            }
            else
            {
                msg = String.Format(message, objectName);
            }

            ValidatorException ex = new ValidatorException(msg, innerException);

            ex.Token = t;

            return(ex);
        }