00001 /* Copyright 2000-2005 The Apache Software Foundation or its licensors, as 00002 * applicable. 00003 * 00004 * Licensed under the Apache License, Version 2.0 (the "License"); 00005 * you may not use this file except in compliance with the License. 00006 * You may obtain a copy of the License at 00007 * 00008 * http://www.apache.org/licenses/LICENSE-2.0 00009 * 00010 * Unless required by applicable law or agreed to in writing, software 00011 * distributed under the License is distributed on an "AS IS" BASIS, 00012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00013 * See the License for the specific language governing permissions and 00014 * limitations under the License. 00015 */ 00016 00017 #ifndef APR_SHM_H 00018 #define APR_SHM_H 00019 00025 #include "apr.h" 00026 #include "apr_pools.h" 00027 #include "apr_errno.h" 00028 00029 #ifdef __cplusplus 00030 extern "C" { 00031 #endif /* __cplusplus */ 00032 00043 typedef struct apr_shm_t apr_shm_t; 00044 00068 APR_DECLARE(apr_status_t) apr_shm_create(apr_shm_t **m, 00069 apr_size_t reqsize, 00070 const char *filename, 00071 apr_pool_t *pool); 00072 00082 APR_DECLARE(apr_status_t) apr_shm_remove(const char *filename, 00083 apr_pool_t *pool); 00084 00089 APR_DECLARE(apr_status_t) apr_shm_destroy(apr_shm_t *m); 00090 00100 APR_DECLARE(apr_status_t) apr_shm_attach(apr_shm_t **m, 00101 const char *filename, 00102 apr_pool_t *pool); 00103 00109 APR_DECLARE(apr_status_t) apr_shm_detach(apr_shm_t *m); 00110 00120 APR_DECLARE(void *) apr_shm_baseaddr_get(const apr_shm_t *m); 00121 00127 APR_DECLARE(apr_size_t) apr_shm_size_get(const apr_shm_t *m); 00128 00132 APR_POOL_DECLARE_ACCESSOR(shm); 00133 00136 #ifdef __cplusplus 00137 } 00138 #endif 00139 00140 #endif /* APR_SHM_T */