Annotation of parser3/src/lib/sdbm/apr-include/apr_file_info.h, revision 1.1

1.1     ! paf         1: /* ====================================================================
        !             2:  * The Apache Software License, Version 1.1
        !             3:  *
        !             4:  * Copyright (c) 2000-2002 The Apache Software Foundation.  All rights
        !             5:  * reserved.
        !             6:  *
        !             7:  * Redistribution and use in source and binary forms, with or without
        !             8:  * modification, are permitted provided that the following conditions
        !             9:  * are met:
        !            10:  *
        !            11:  * 1. Redistributions of source code must retain the above copyright
        !            12:  *    notice, this list of conditions and the following disclaimer.
        !            13:  *
        !            14:  * 2. Redistributions in binary form must reproduce the above copyright
        !            15:  *    notice, this list of conditions and the following disclaimer in
        !            16:  *    the documentation and/or other materials provided with the
        !            17:  *    distribution.
        !            18:  *
        !            19:  * 3. The end-user documentation included with the redistribution,
        !            20:  *    if any, must include the following acknowledgment:
        !            21:  *       "This product includes software developed by the
        !            22:  *        Apache Software Foundation (http://www.apache.org/)."
        !            23:  *    Alternately, this acknowledgment may appear in the software itself,
        !            24:  *    if and wherever such third-party acknowledgments normally appear.
        !            25:  *
        !            26:  * 4. The names "Apache" and "Apache Software Foundation" must
        !            27:  *    not be used to endorse or promote products derived from this
        !            28:  *    software without prior written permission. For written
        !            29:  *    permission, please contact apache@apache.org.
        !            30:  *
        !            31:  * 5. Products derived from this software may not be called "Apache",
        !            32:  *    nor may "Apache" appear in their name, without prior written
        !            33:  *    permission of the Apache Software Foundation.
        !            34:  *
        !            35:  * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
        !            36:  * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
        !            37:  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
        !            38:  * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
        !            39:  * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
        !            40:  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
        !            41:  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
        !            42:  * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
        !            43:  * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
        !            44:  * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
        !            45:  * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
        !            46:  * SUCH DAMAGE.
        !            47:  * ====================================================================
        !            48:  *
        !            49:  * This software consists of voluntary contributions made by many
        !            50:  * individuals on behalf of the Apache Software Foundation.  For more
        !            51:  * information on the Apache Software Foundation, please see
        !            52:  * <http://www.apache.org/>.
        !            53:  */
        !            54: 
        !            55: #ifndef APR_FILE_INFO_H
        !            56: #define APR_FILE_INFO_H
        !            57: 
        !            58: #include "apr.h"
        !            59: 
        !            60: #ifdef __cplusplus
        !            61: extern "C" {
        !            62: #endif /* __cplusplus */
        !            63: /**
        !            64:  * @file apr_file_info.h
        !            65:  * @brief APR File handling
        !            66:  */
        !            67: 
        !            68: /**
        !            69:  * Structure for determining file permissions.
        !            70:  * @defvar apr_fileperms_t
        !            71:  */
        !            72: typedef apr_int32_t               apr_fileperms_t;
        !            73: 
        !            74: /**
        !            75:  * @defgroup APR_File_Info Stat Functions
        !            76:  * @{
        !            77:  */
        !            78: #ifdef LATER
        !            79: #define APR_FINFO_LINK   0x00000001 /**< Stat the link not the file itself if it is a link */
        !            80: #define APR_FINFO_MTIME  0x00000010 /**< Modification Time */
        !            81: #define APR_FINFO_CTIME  0x00000020 /**< Creation Time */
        !            82: #define APR_FINFO_ATIME  0x00000040 /**< Access Time */
        !            83: #endif
        !            84: #define APR_FINFO_SIZE   0x00000100 /**< Size of the file */
        !            85: #ifdef LATER
        !            86: #define APR_FINFO_CSIZE  0x00000200 /**< Storage size consumed by the file */
        !            87: #define APR_FINFO_DEV    0x00001000
        !            88: #define APR_FINFO_INODE  0x00002000
        !            89: #define APR_FINFO_NLINK  0x00004000
        !            90: #define APR_FINFO_TYPE   0x00008000
        !            91: #define APR_FINFO_USER   0x00010000 
        !            92: #define APR_FINFO_GROUP  0x00020000 
        !            93: #define APR_FINFO_UPROT  0x00100000 
        !            94: #define APR_FINFO_GPROT  0x00200000
        !            95: #define APR_FINFO_WPROT  0x00400000
        !            96: #define APR_FINFO_ICASE  0x01000000  /**<  if dev is case insensitive */
        !            97: #define APR_FINFO_NAME   0x02000000  /**<  ->name in proper case */
        !            98: 
        !            99: #define APR_FINFO_MIN    0x00008170  /**<  type, mtime, ctime, atime, size */
        !           100: #define APR_FINFO_IDENT  0x00003000  /**<  dev and inode */
        !           101: #define APR_FINFO_OWNER  0x00030000  /**<  user and group */
        !           102: #define APR_FINFO_PROT   0x00700000  /**<  all protections */
        !           103: #define APR_FINFO_NORM   0x0073b170  /**<  an atomic unix apr_stat() */
        !           104: #define APR_FINFO_DIRENT 0x02000000  /**<  an atomic unix apr_dir_read() */
        !           105: #endif
        !           106: 
        !           107: /**
        !           108:  * The file information structure.  This is analogous to the POSIX
        !           109:  * stat structure.
        !           110:  */
        !           111: typedef struct apr_finfo_t        apr_finfo_t;
        !           112: 
        !           113: struct apr_finfo_t {
        !           114: #ifdef LATER
        !           115:        /** Allocates memory and closes lingering handles in the specified pool */
        !           116:     apr_pool_t *pool;
        !           117:     /** The bitmask describing valid fields of this apr_finfo_t structure 
        !           118:      *  including all available 'wanted' fields and potentially more */
        !           119:     apr_int32_t valid;
        !           120:     /** The access permissions of the file.  Mimics Unix access rights. */
        !           121:     apr_fileperms_t protection;
        !           122:     /** The type of file.  One of APR_NOFILE, APR_REG, APR_DIR, APR_CHR, 
        !           123:      *  APR_BLK, APR_PIPE, APR_LNK, APR_SOCK 
        !           124:      */
        !           125:     apr_filetype_e filetype;
        !           126:     /** The user id that owns the file */
        !           127:     apr_uid_t user;
        !           128:     /** The group id that owns the file */
        !           129:     apr_gid_t group;
        !           130:     /** The inode of the file. */
        !           131:     apr_ino_t inode;
        !           132:     /** The id of the device the file is on. */
        !           133:     apr_dev_t device;
        !           134:     /** The number of hard links to the file. */
        !           135:     apr_int32_t nlink;
        !           136: #endif
        !           137:     /** The size of the file */
        !           138:     apr_off_t size;
        !           139: #ifdef LATER
        !           140:     /** The storage size consumed by the file */
        !           141:     apr_off_t csize;
        !           142:     /** The time the file was last accessed */
        !           143:     apr_time_t atime;
        !           144:     /** The time the file was last modified */
        !           145:     apr_time_t mtime;
        !           146:     /** The time the file was last changed */
        !           147:     apr_time_t ctime;
        !           148:     /** The full pathname of the file */
        !           149:     const char *fname;
        !           150:     /** The file's name (no path) in filesystem case */
        !           151:     const char *name;
        !           152:     /** The file's handle, if accessed (can be submitted to apr_duphandle) */
        !           153:     struct apr_file_t *filehand;
        !           154: #endif
        !           155: };
        !           156: 
        !           157: /** @} */
        !           158: 
        !           159: 
        !           160: 
        !           161: #ifdef __cplusplus
        !           162: }
        !           163: #endif
        !           164: 
        !           165: #endif  /* ! APR_FILE_INFO_H */

E-mail: