1 /* ------------------------------------------------------------------ 2 * Copyright (C) 1998-2009 PacketVideo 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either 13 * express or implied. 14 * See the License for the specific language governing permissions 15 * and limitations under the License. 16 * ------------------------------------------------------------------- 17 */ 18 19 /*! \addtogroup osclproc OSCL Proc 20 * 21 * @{ 22 */ 23 24 /** \file oscl_aostatus.h 25 \brief Some basic types used with active objects. 26 */ 27 #ifndef OSCL_AOSTATUS_H_INCLUDED 28 #define OSCL_AOSTATUS_H_INCLUDED 29 30 #ifndef OSCLCONFIG_PROC_H_INCLUDED 31 #include "osclconfig_proc.h" 32 #endif 33 34 35 #ifndef OSCL_BASE_H_INCLUDED 36 #include "oscl_base.h" 37 #endif 38 39 //Request status values. These are negative so that 40 //they won't conflict with system error codes. 41 const int32 OSCL_REQUEST_ERR_NONE = 0; 42 const int32 OSCL_REQUEST_PENDING = (-0x7fffffff); 43 const int32 OSCL_REQUEST_ERR_CANCEL = (-1); 44 const int32 OSCL_REQUEST_ERR_GENERAL = (-2); 45 46 47 //Request status type 48 class OsclAOStatus 49 { 50 public: 51 OSCL_INLINE OsclAOStatus(); 52 OSCL_INLINE OsclAOStatus(int32 aStatus); 53 OSCL_INLINE int32 operator=(int32 aStatus); 54 OSCL_INLINE int32 operator==(int32 aStatus) const; 55 OSCL_INLINE int32 operator!=(int32 aStatus) const; 56 OSCL_INLINE int32 operator>=(int32 aStatus) const; 57 OSCL_INLINE int32 operator<=(int32 aStatus) const; 58 OSCL_INLINE int32 operator>(int32 aStatus) const; 59 OSCL_INLINE int32 operator<(int32 aStatus) const; 60 OSCL_INLINE int32 Value() const; 61 private: 62 int32 iStatus; 63 }; 64 65 66 #if !(OSCL_DISABLE_INLINES) 67 #include "oscl_aostatus.inl" 68 #endif 69 70 71 #endif 72 73 /*! @} */ 74