internal override ProcessingMessage Register(ProcessingErrorCode code, Severity severity, ObjectType objectType, string objectName, string propertyName, ProcessingMessageList innerMessages, params string[] arguments) { try { Monitor.Enter(this); if (severity == Severity.Error) { m_hasError = true; } if (RegisterItem(severity, code, objectType, objectName)) { if (m_messages == null) { m_messages = new ProcessingMessageList(); } ProcessingMessage processingMessage = ErrorContext.CreateProcessingMessage(code, severity, objectType, objectName, propertyName, innerMessages, arguments); m_messages.Add(processingMessage); return(processingMessage); } return(null); } finally { Monitor.Exit(this); } }