Process this error message.
Using this message, lookup the correct error processor and run it, using this error text.
@param messageOut
@param strMessageError
@return Reply Error Message (internal format).
777327
public static BaseMessage processErrorMessage(RecordOwner recordOwner, BaseMessage messageOut, String strMessageError)
    {
        if (strMessageError != null)  // Add the error message to the message so the error processor has the right desc.
            ((TrxMessageHeader)messageOut.getMessageHeader()).put(TrxMessageHeader.MESSAGE_ERROR, strMessageError); // Error Description
        // Get the error message processor for this message/message type
        String strDefaultProcessorClass = null;
        MessageProcessInfoModel recMessageProcessInfo = (MessageProcessInfoModel)recordOwner.getRecord(MessageProcessInfoModel.MESSAGE_PROCESS_INFO_FILE);
        if (recMessageProcessInfo == null)
            recMessageProcessInfo = (MessageProcessInfoModel)Record.makeRecordFromClassName(MessageProcessInfo.THICK_CLASS, recordOwner);
        Object objResponseID = messageOut.getMessageHeader().get(TrxMessageHeader.MESSAGE_ERROR_PROCESSOR);

        if (objResponseID != null)
        {
            if (Utility.isNumeric(objResponseID.toString()))
            {
                recMessageProcessInfo = recMessageProcessInfo.getMessageProcessInfo(objResponseID.toString());
                if (recMessageProcessInfo != null)
                    strDefaultProcessorClass = recMessageProcessInfo.getField(MessageProcessInfo.PROCESSOR_CLASS).toString();
            }
            else
                strDefaultProcessorClass = objResponseID.toString();
        }
        if (strDefaultProcessorClass == null)
        {
            String strMessageProcessInfoID = (String)messageOut.getMessageHeader().get(TrxMessageHeader.MESSAGE_PROCESS_INFO_ID);
            recMessageProcessInfo = recMessageProcessInfo.getMessageProcessInfo(strMessageProcessInfoID);
            if (recMessageProcessInfo != null)
            {
                Record recMessageInfo = ((ReferenceField)recMessageProcessInfo.getField(MessageProcessInfoModel.MESSAGE_INFO_ID)).getReference();
                if (recMessageInfo != null)
                    if ((recMessageInfo.getEditMode() == DBConstants.EDIT_CURRENT) || (recMessageInfo.getEditMode() == DBConstants.EDIT_IN_PROGRESS))
                {
                    String strMessageInfoType = ((ReferenceField)recMessageInfo.getField(MessageInfoModel.MESSAGE_INFO_TYPE_ID)).getReference().getField(MessageInfoTypeModel.CODE).toString();
                    String strContactType = ((ReferenceField)recMessageInfo.getField(MessageInfoModel.CONTACT_TYPE_ID)).getReference().getField(ContactTypeModel.CODE).toString();
                    String strRequestType = RequestTypeModel.ERROR; 
                    String strMessageProcessType = ((ReferenceField)recMessageProcessInfo.getField(MessageProcessInfoModel.MESSAGE_TYPE_ID)).getReference().getField(MessageTypeModel.CODE).toString();
                    String strProcessType = ((ReferenceField)recMessageProcessInfo.getField(MessageProcessInfoModel.PROCESS_TYPE_ID)).getReference().getField(ProcessTypeModel.CODE).toString();
                    
                    recMessageProcessInfo = recMessageProcessInfo.getMessageProcessInfo(strMessageInfoType, strContactType, strRequestType, strMessageProcessType, strProcessType);
                    if (recMessageProcessInfo != null)
                        strDefaultProcessorClass = recMessageProcessInfo.getField(MessageProcessInfoModel.PROCESSOR_CLASS).toString();
                }
            }
        }
        if (strDefaultProcessorClass == null)
            strDefaultProcessorClass = BaseMessageErrorProcessor.class.getName();
        // Process this error
        BaseMessageProcessor messageInProcessor = (BaseMessageProcessor)BaseMessageProcessor.getMessageProcessor(recordOwner.getTask(), null, strDefaultProcessorClass);
        Utility.getLogger().info("processIncommingMessage - processor: " + messageInProcessor);
        BaseMessage errorMessage = null;
        if (messageInProcessor != null)
        {   // Always
            errorMessage = messageInProcessor.processMessage(messageOut);
            messageInProcessor.free();
        }
        return errorMessage;
    }
610821
private void reply(final String response, final boolean error,
            final String errorMessage, final String stackTrace,
            final String statusCode, final int statusCodeInt,
            Map<String, List<String>> responseHeaders) {

        if (!sentReply) {
            // must update sentReply first to avoid duplicated msg.
            sentReply = true;

            final ResponseOnSingeRequest res = new ResponseOnSingeRequest(
                    response, error, errorMessage, stackTrace, statusCode,
                    statusCodeInt, PcDateUtils.getNowDateTimeStrStandard(),
                    responseHeaders);
            if (!getContext().system().deadLetters().equals(sender)) {
                sender.tell(res, getSelf());
            }
            if (getContext() != null) {
                getContext().stop(getSelf());
            }
        }

    }
747380
protected void applyErrorMessage(@Nullable CharSequence errorMessage) {
        if (mErrorView instanceof TextView) {
            ((TextView) mErrorView).setText(errorMessage);
        }
    }
844169
@SuppressWarnings("checkstyle:regexp")
	public static void showError(String message, Throwable exception) {
		try (PrintWriter logger = new PrintWriter(getConsoleLogger())) {
			if (message != null && !message.isEmpty()) {
				logger.println(message);
			} else if (exception != null) {
				exception.printStackTrace(logger);
			}
			logger.println();
			logger.flush();
			showHelp(logger, false);
			showVersion(true);
		}
	}
362878
function parseError (parser) {
  var string = parseSimpleString(parser)
  if (string !== undefined) {
    if (parser.optionReturnBuffers === true) {
      string = string.toString()
    }
    return new ReplyError(string)
  }
}
713109
private void printErrorAndQuit(String message)
    {
        System.out.println(message + "\n-------------------------------------------------------------------------------------\n");
        printUsage();
        System.exit(-1);
    }
598002
protected void error(String msg) {
		System.err.println(CSLToolContext.current().getToolName() + ": " + msg);
	}
673362
@Override
    public void sendError(HttpError error) throws MessageSentException {
        if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
            Tr.debug(tc, "Called sendError with: " + error);
        }
        if (!headersParsed()) {
            // request message must have the headers parsed prior to sending
            // any data out (this is a completely invalid state in the channel
            // above)
            // In this case, the app should not be re-using this so just close it
            IOException ioe = new IOException("Request not read yet");
            FFDCFilter.processException(ioe, CLASS_NAME + ".sendError", "1116");
            if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
                Tr.debug(tc, "Attempt to send response without a request msg");
            }
            finishSendError(ioe);
            return;
        }

        // bail if the headers have already been sent
        if (headersSent()) {
            throw new MessageSentException("Message already sent");
        }

        // ensure error is legal
        if (null == error) {
            if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
                Tr.debug(tc, "Reset null error to Internal Server Error");
            }
            error = StatusCodes.INTERNAL_ERROR.getHttpError();
        }

        // set up the response message and then send it out
        getResponse().setStatusCode(error.getErrorCode());
        if (getResponse().getStatusCode().isErrorCode()) {
            // PK30169 - some "error" status codes do not disable persistence
            setPersistent(false);
        }
        getVC().getStateMap().put(HTTP_ERROR_IDENTIFIER, error);
        if (getHttpConfig().getDebugLog().isEnabled(DebugLog.Level.ERROR)) {
            getHttpConfig().getDebugLog().log(DebugLog.Level.ERROR, HttpMessages.MSG_CONN_SENDERROR + error.getErrorCode(), this);
        }
        // now figure out what buffers, if any, to send as the response body
        WsByteBuffer[] body = loadErrorBody(error, getMyRequest(), getResponse());
        VirtualConnection rc = finishResponseMessage(body, HttpISCWriteErrorCallback.getRef(), false);
        if (null != rc) {
            finishSendError(error.getClosingException());
        }
    }
823645
private final void replyErrors(final String errorMessage,
            final String stackTrace, final String statusCode,
            final int statusCodeInt) {
        reply(true, errorMessage, stackTrace, statusCode, statusCodeInt,
                PcConstants.NA, null);

    }
261039
public void sendError(HttpResponse response,int code,String msg)
    	throws IOException
    {
        Object wrapper = response.getWrapper();
        if (wrapper!=null && wrapper instanceof HttpServletResponse)
            ((HttpServletResponse)wrapper).sendError(code,msg);
        else
            super.sendError(response,code,msg);
    }
281289
public void reportSqlError(String message, java.sql.SQLException sqlEx)
    {
        StringBuffer strBufMessages = new StringBuffer();
        java.sql.SQLException currentSqlEx = sqlEx;
        do
        {
            strBufMessages.append("\n" + sqlEx.getErrorCode() + ":" + sqlEx.getMessage());
            currentSqlEx = currentSqlEx.getNextException();
        } while (currentSqlEx != null);        
        System.err.println(message + strBufMessages.toString());
        sqlEx.printStackTrace();
    }
1311325
private String createError(String errorMsg) {

        StringBuffer result = new StringBuffer();

        result.append("ERR");
        result.append(errorMsg);

        return result.toString();
    }
58475
def _on_process_error(self, error):
        
        if self is None:
            return
        err = PROCESS_ERROR_STRING[error]
        self._formatter.append_message(err + '\r\n', output_format=OutputFormat.ErrorMessageFormat)
887627
@Override
    public void error(String msg, Throwable e) {
        log.logIfEnabled(FQCN, Level.ERROR, null, msg, e);
    }
680370
void logError(final String message) {
      if(logger != null) {
         try {
            StringBuilder buf = new StringBuilder(name);
            buf.append(":");
            buf.append(message);
            logger.error(buf.toString());            
         } catch(Throwable t) {
            //Ignore - logging should not kill anything
         }
      }
   }
975995
private Exception updateErrorMsg(StringBuilder pErrors, Exception exp) {
        pErrors.append(exp.getClass()).append(": ").append(exp.getMessage()).append("\n");
        return exp;
    }
172822
public void setErrorReturn(PrintWriter out, RemoteException ex)
        throws RemoteException
    {
        out.println(Utility.startTag(XMLTags.STATUS_TEXT));
        String strMessage = ex.getLocalizedMessage();
        if (Utility.isNumeric(strMessage))
        {
            try {
                int iErrorCode = Integer.parseInt(strMessage);
                out.println(Utility.startTag(XMLTags.ERROR_CODE) + strMessage + Utility.endTag(XMLTags.ERROR_CODE));
                if (this.getTask() != null)
                    if (this.getTask().getApplication() != null)
                        strMessage = this.getTask().getApplication().getSecurityErrorText(iErrorCode);
            } catch (NumberFormatException ex2) {
                // Ignore
            }
        }
        out.println(Utility.startTag(XMLTags.TEXT) + strMessage + Utility.endTag(XMLTags.TEXT));
        out.println(Utility.startTag(XMLTags.ERROR) + "error" + Utility.endTag(XMLTags.ERROR));
        out.println(Utility.endTag(XMLTags.STATUS_TEXT));
        return;
    }