libXDispatch 0.3.1
include/libdispatch/group.h
Go to the documentation of this file.
00001 /*
00002 * Copyright (c) 2008-2009 Apple Inc. All rights reserved.
00003 * Copyright (c) 2011 MLBA. All rights reserved.
00004 *
00005 * @MLBA_OPEN_LICENSE_HEADER_START@
00006 *
00007 * Licensed under the Apache License, Version 2.0 (the "License");
00008 * you may not use this file except in compliance with the License.
00009 * You may obtain a copy of the License at
00010 * 
00011 *     http://www.apache.org/licenses/LICENSE-2.0
00012 * 
00013 * Unless required by applicable law or agreed to in writing, software
00014 * distributed under the License is distributed on an "AS IS" BASIS,
00015 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00016 * See the License for the specific language governing permissions and
00017 * limitations under the License.
00018 *
00019 * @MLBA_OPEN_LICENSE_HEADER_END@
00020 */
00021 
00022 
00023 
00024 #ifndef __DISPATCH_GROUP__
00025 #define __DISPATCH_GROUP__
00026 
00027 #ifndef __DISPATCH_INDIRECT__
00028 #error "Please #include <xdispatch/dispatch.h> instead of this file directly."
00029 #include "base.h" // for HeaderDoc
00030 #endif
00031 
00037 DISPATCH_DECL(dispatch_group);
00038 
00039 __DISPATCH_BEGIN_DECLS
00040 
00055 DISPATCH_EXPORT dispatch_group_t
00056 dispatch_group_create(void);
00057 
00081 #ifdef XDISPATCH_HAS_BLOCKS
00082 DISPATCH_EXPORT void
00083 dispatch_group_async(dispatch_group_t group,
00084        dispatch_queue_t queue,
00085        dispatch_block_t block);
00086 #endif /* XDISPATCH_HAS_BLOCKS */
00087 
00114 DISPATCH_EXPORT void
00115 dispatch_group_async_f(dispatch_group_t group,
00116        dispatch_queue_t queue,
00117        void *context,
00118        dispatch_function_t work);
00119 
00155 DISPATCH_EXPORT long
00156 dispatch_group_wait(dispatch_group_t group, dispatch_time_t timeout);
00157 
00188 #ifdef XDISPATCH_HAS_BLOCKS
00189 DISPATCH_EXPORT void
00190 dispatch_group_notify(dispatch_group_t group,
00191        dispatch_queue_t queue,
00192        dispatch_block_t block);
00193 #endif /* XDISPATCH_HAS_BLOCKS */
00194 
00217 DISPATCH_EXPORT void
00218 dispatch_group_notify_f(dispatch_group_t group,
00219        dispatch_queue_t queue,
00220        void *context,
00221        dispatch_function_t work);
00222 
00238 DISPATCH_EXPORT void
00239 dispatch_group_enter(dispatch_group_t group);
00240 
00255 DISPATCH_EXPORT void
00256 dispatch_group_leave(dispatch_group_t group);
00257 
00258 __DISPATCH_END_DECLS
00259 
00260 #endif

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