libXDispatch 0.4
include/libdispatch/group.h
Go to the documentation of this file.
00001 /*
00002  * Copyright (c) 2008-2009 Apple Inc. All rights reserved.
00003  *
00004  * @APPLE_APACHE_LICENSE_HEADER_START@
00005  * 
00006  * Licensed under the Apache License, Version 2.0 (the "License");
00007  * you may not use this file except in compliance with the License.
00008  * You may obtain a copy of the License at
00009  * 
00010  *     http://www.apache.org/licenses/LICENSE-2.0
00011  * 
00012  * Unless required by applicable law or agreed to in writing, software
00013  * distributed under the License is distributed on an "AS IS" BASIS,
00014  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00015  * See the License for the specific language governing permissions and
00016  * limitations under the License.
00017  * 
00018  * @APPLE_APACHE_LICENSE_HEADER_END@
00019  */
00020 
00021 #ifndef __DISPATCH_GROUP__
00022 #define __DISPATCH_GROUP__
00023 
00024 #ifndef __DISPATCH_INDIRECT__
00025 #error "Please #include <xdispatch/dispatch.h> instead of this file directly."
00026 #include "base.h" // for HeaderDoc
00027 #endif
00028 
00034 DISPATCH_DECL(dispatch_group);
00035 
00036 __DISPATCH_BEGIN_DECLS
00037 
00052 __OSX_AVAILABLE_STARTING(__MAC_10_6,__IPHONE_4_0)
00053 DISPATCH_EXPORT DISPATCH_WARN_RESULT
00054 dispatch_group_t
00055 dispatch_group_create(void);
00056 
00080 #ifdef __BLOCKS__
00081 __OSX_AVAILABLE_STARTING(__MAC_10_6,__IPHONE_4_0)
00082 DISPATCH_EXPORT DISPATCH_NONNULL_ALL
00083 void
00084 dispatch_group_async(dispatch_group_t group,
00085        dispatch_queue_t queue,
00086        dispatch_block_t block);
00087 #endif /* __BLOCKS__ */
00088 
00115 __OSX_AVAILABLE_STARTING(__MAC_10_6,__IPHONE_4_0)
00116 DISPATCH_EXPORT DISPATCH_NONNULL1 DISPATCH_NONNULL2 DISPATCH_NONNULL4
00117 void
00118 dispatch_group_async_f(dispatch_group_t group,
00119        dispatch_queue_t queue,
00120        void *context,
00121        dispatch_function_t work);
00122 
00158 __OSX_AVAILABLE_STARTING(__MAC_10_6,__IPHONE_4_0)
00159 DISPATCH_EXPORT DISPATCH_NONNULL_ALL
00160 long
00161 dispatch_group_wait(dispatch_group_t group, dispatch_time_t timeout);
00162 
00193 #ifdef __BLOCKS__
00194 __OSX_AVAILABLE_STARTING(__MAC_10_6,__IPHONE_4_0)
00195 DISPATCH_EXPORT DISPATCH_NONNULL_ALL
00196 void
00197 dispatch_group_notify(dispatch_group_t group,
00198        dispatch_queue_t queue,
00199        dispatch_block_t block);
00200 #endif /* __BLOCKS__ */
00201 
00224 __OSX_AVAILABLE_STARTING(__MAC_10_6,__IPHONE_4_0)
00225 DISPATCH_EXPORT DISPATCH_NONNULL1 DISPATCH_NONNULL2 DISPATCH_NONNULL4
00226 void
00227 dispatch_group_notify_f(dispatch_group_t group,
00228        dispatch_queue_t queue,
00229        void *context,
00230        dispatch_function_t work);
00231 
00247 __OSX_AVAILABLE_STARTING(__MAC_10_6,__IPHONE_4_0)
00248 DISPATCH_EXPORT DISPATCH_NOTHROW DISPATCH_NONNULL_ALL
00249 void
00250 dispatch_group_enter(dispatch_group_t group);
00251 
00266 __OSX_AVAILABLE_STARTING(__MAC_10_6,__IPHONE_4_0)
00267 DISPATCH_EXPORT DISPATCH_NOTHROW DISPATCH_NONNULL_ALL
00268 void
00269 dispatch_group_leave(dispatch_group_t group);
00270 
00271 __DISPATCH_END_DECLS
00272 
00273 #endif

Generated on Wed Feb 22 2012 19:51:17 for libXDispatch by Doxygen 1.7.4
Content © 2011-2012 MLBA (about | privacy) – Design © 2010-2012 Emzeat. All Rights reserved.