|
UDK 3.2.7 C/C++ API Reference
|
00001 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ 00002 /* 00003 * This file is part of the LibreOffice project. 00004 * 00005 * This Source Code Form is subject to the terms of the Mozilla Public 00006 * License, v. 2.0. If a copy of the MPL was not distributed with this 00007 * file, You can obtain one at http://mozilla.org/MPL/2.0/. 00008 * 00009 * This file incorporates work covered by the following license notice: 00010 * 00011 * Licensed to the Apache Software Foundation (ASF) under one or more 00012 * contributor license agreements. See the NOTICE file distributed 00013 * with this work for additional information regarding copyright 00014 * ownership. The ASF licenses this file to you under the Apache 00015 * License, Version 2.0 (the "License"); you may not use this file 00016 * except in compliance with the License. You may obtain a copy of 00017 * the License at http://www.apache.org/licenses/LICENSE-2.0 . 00018 */ 00019 00020 #ifndef _OSL_SIGNAL_H_ 00021 #define _OSL_SIGNAL_H_ 00022 00023 #include "sal/config.h" 00024 00025 #include "sal/saldllapi.h" 00026 #include "sal/types.h" 00027 00028 #ifdef __cplusplus 00029 extern "C" { 00030 #endif 00031 00032 #define OSL_SIGNAL_USER_RESERVED 0 00033 00034 #define OSL_SIGNAL_USER_RESOURCEFAILURE (OSL_SIGNAL_USER_RESERVED - 1) 00035 #define OSL_SIGNAL_USER_X11SUBSYSTEMERROR (OSL_SIGNAL_USER_RESERVED - 2) 00036 #define OSL_SIGNAL_USER_RVPCONNECTIONERROR (OSL_SIGNAL_USER_RESERVED - 3) 00037 00038 typedef void* oslSignalHandler; 00039 00040 typedef enum 00041 { 00042 osl_Signal_System, 00043 osl_Signal_Terminate, 00044 osl_Signal_AccessViolation, 00045 osl_Signal_IntegerDivideByZero, 00046 osl_Signal_FloatDivideByZero, 00047 osl_Signal_DebugBreak, 00048 osl_Signal_User, 00049 osl_Signal_Alarm, 00050 osl_Signal_FORCE_EQUAL_SIZE = SAL_MAX_ENUM 00051 } oslSignal; 00052 00053 typedef enum 00054 { 00055 osl_Signal_ActCallNextHdl, 00056 osl_Signal_ActIgnore, 00057 osl_Signal_ActAbortApp, 00058 osl_Signal_ActKillApp, 00059 osl_Signal_Act_FORCE_EQUAL_SIZE = SAL_MAX_ENUM 00060 } oslSignalAction; 00061 00062 #ifdef SAL_W32 00063 # pragma pack(push, 8) 00064 #endif 00065 00066 typedef struct 00067 { 00068 oslSignal Signal; 00069 sal_Int32 UserSignal; 00070 void* UserData; 00071 } oslSignalInfo; 00072 00073 #if defined( SAL_W32) 00074 # pragma pack(pop) 00075 #endif 00076 00079 typedef oslSignalAction (SAL_CALL *oslSignalHandlerFunction)(void* pData, oslSignalInfo* pInfo); 00080 00081 SAL_DLLPUBLIC oslSignalHandler SAL_CALL osl_addSignalHandler( 00082 oslSignalHandlerFunction Handler, void* pData); 00083 00084 SAL_DLLPUBLIC sal_Bool SAL_CALL osl_removeSignalHandler( 00085 oslSignalHandler hHandler); 00086 00087 SAL_DLLPUBLIC oslSignalAction SAL_CALL osl_raiseSignal( 00088 sal_Int32 UserSignal, void* UserData); 00089 00102 SAL_DLLPUBLIC sal_Bool SAL_CALL osl_setErrorReporting( 00103 sal_Bool bEnable ); 00104 00105 #ifdef __cplusplus 00106 } 00107 #endif 00108 00109 #endif /* _OSL_SIGNAL_H_ */ 00110 00111 00112 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
1.7.3