コード例 #1
0
ファイル: messagefactory.cpp プロジェクト: acekiller/povray
void MessageFactory::ErrorAt(Exception& ex, const UCS2 *filename, POV_LONG line, POV_LONG column, POV_LONG offset, const char *format, ...)
{
	va_list marker;

	if (ex.frontendnotified(true))
		throw ex;

	va_start(marker, format);
	SendError(format, marker, filename, line, column, offset);
	va_end(marker);

	throw ex;
}
コード例 #2
0
void RenderTask::SendFatalError(Exception& e)
{
    // if the front-end has been told about this exception already, we don't tell it again
    if (e.frontendnotified(true))
        return;

    POVMS_Message msg(kPOVObjectClass_ControlData, kPOVMsgClass_ViewOutput, kPOVMsgIdent_Error);

    msg.SetString(kPOVAttrib_EnglishText, e.what());
    msg.SetInt(kPOVAttrib_Error, 0);
    msg.SetInt(kPOVAttrib_ViewId, viewData->GetViewId());
    msg.SetSourceAddress(viewData->GetSceneData()->backendAddress);
    msg.SetDestinationAddress(viewData->GetSceneData()->frontendAddress);

    POVMS_SendMessage(msg);
}
コード例 #3
0
ファイル: messagefactory.cpp プロジェクト: acekiller/povray
void MessageFactory::Error(Exception& ex, const char *format, ...)
{
	va_list marker;

	// if the front-end has been told about this exception already, we don't want to tell it again
	// (we presume that the text given by format and its parameters relate to that exception)
	// this form of frontendnotified() sets the notified state of ex
	if (ex.frontendnotified(true))
		throw ex;

	va_start(marker, format);
	SendError(format, marker);
	va_end(marker);

	// Terminate
	throw ex;
}
コード例 #4
0
ファイル: messagefactory.cpp プロジェクト: acekiller/povray
void MessageFactory::Error(const Exception& ex, const char *format, ...)
{
	va_list marker;

	// if the front-end has been told about this exception already, we don't want to tell it again
	// (we presume that the text given by format and its parameters relate to that exception)
	// this form of frontendnotified() doesn't change the state of ex
	if (ex.frontendnotified())
		throw ex;

	va_start(marker, format);
	SendError(format, marker);
	va_end(marker);

	// now take a copy of ex and set its notification flag, then throw that.
	pov_base::Exception local_ex(ex);
	local_ex.frontendnotified(true);
	throw local_ex;
}