1*514f4c20SAndrew Rist /************************************************************** 2cdf0e10cSrcweir * 3*514f4c20SAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one 4*514f4c20SAndrew Rist * or more contributor license agreements. See the NOTICE file 5*514f4c20SAndrew Rist * distributed with this work for additional information 6*514f4c20SAndrew Rist * regarding copyright ownership. The ASF licenses this file 7*514f4c20SAndrew Rist * to you under the Apache License, Version 2.0 (the 8*514f4c20SAndrew Rist * "License"); you may not use this file except in compliance 9*514f4c20SAndrew Rist * with the License. You may obtain a copy of the License at 10*514f4c20SAndrew Rist * 11*514f4c20SAndrew Rist * http://www.apache.org/licenses/LICENSE-2.0 12*514f4c20SAndrew Rist * 13*514f4c20SAndrew Rist * Unless required by applicable law or agreed to in writing, 14*514f4c20SAndrew Rist * software distributed under the License is distributed on an 15*514f4c20SAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16*514f4c20SAndrew Rist * KIND, either express or implied. See the License for the 17*514f4c20SAndrew Rist * specific language governing permissions and limitations 18*514f4c20SAndrew Rist * under the License. 19*514f4c20SAndrew Rist * 20*514f4c20SAndrew Rist *************************************************************/ 21*514f4c20SAndrew Rist 22*514f4c20SAndrew Rist 23cdf0e10cSrcweir #ifndef _UNO_CUNO_H_ 24cdf0e10cSrcweir #define _UNO_CUNO_H_ 25cdf0e10cSrcweir 26cdf0e10cSrcweir #include <sal/types.h> 27cdf0e10cSrcweir 28cdf0e10cSrcweir #define CUNO_ERROR_NONE 0 29cdf0e10cSrcweir #define CUNO_ERROR_CALL_FAILED (1 << 31) 30cdf0e10cSrcweir #define CUNO_ERROR_EXCEPTION (1 | CUNO_ERROR_CALL_FAILED) 31cdf0e10cSrcweir 32cdf0e10cSrcweir /** macro to call on a C interface 33cdf0e10cSrcweir 34cdf0e10cSrcweir @param interface_pointer interface pointer 35cdf0e10cSrcweir */ 36cdf0e10cSrcweir #define CUNO_CALL( interface_pointer ) (*interface_pointer) 37cdf0e10cSrcweir /** macro to test if an exception was signalled. 38cdf0e10cSrcweir 39cdf0e10cSrcweir @param return_code return code of call 40cdf0e10cSrcweir */ 41cdf0e10cSrcweir #define CUNO_EXCEPTION_OCCURED( return_code ) (0 != ((return_code) & CUNO_ERROR_EXCEPTION)) 42cdf0e10cSrcweir 43cdf0e10cSrcweir typedef sal_Int32 cuno_ErrorCode; 44cdf0e10cSrcweir 45cdf0e10cSrcweir #endif 46cdf0e10cSrcweir 47