Back to home page

EIC code displayed by LXR

 
 

    


Warning, file /include/xrootd/private/XrdZip/XrdZipDataDescriptor.hh was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).

0001 //------------------------------------------------------------------------------
0002 // Copyright (c) 2011-2014 by European Organization for Nuclear Research (CERN)
0003 // Author: Michal Simon <michal.simon@cern.ch>
0004 //------------------------------------------------------------------------------
0005 // This file is part of the XRootD software suite.
0006 //
0007 // XRootD is free software: you can redistribute it and/or modify
0008 // it under the terms of the GNU Lesser General Public License as published by
0009 // the Free Software Foundation, either version 3 of the License, or
0010 // (at your option) any later version.
0011 //
0012 // XRootD is distributed in the hope that it will be useful,
0013 // but WITHOUT ANY WARRANTY; without even the implied warranty of
0014 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
0015 // GNU General Public License for more details.
0016 //
0017 // You should have received a copy of the GNU Lesser General Public License
0018 // along with XRootD.  If not, see <http://www.gnu.org/licenses/>.
0019 //
0020 // In applying this licence, CERN does not waive the privileges and immunities
0021 // granted to it by virtue of its status as an Intergovernmental Organization
0022 // or submit itself to any jurisdiction.
0023 //------------------------------------------------------------------------------
0024 
0025 #ifndef SRC_XRDZIP_XRDZIPDATADESCRIPTOR_HH_
0026 #define SRC_XRDZIP_XRDZIPDATADESCRIPTOR_HH_
0027 
0028 #include <cstdint>
0029 
0030 namespace XrdZip
0031 {
0032   //---------------------------------------------------------------------------
0033   // A data structure representing the Data Descriptor record
0034   //---------------------------------------------------------------------------
0035   struct DataDescriptor
0036   {
0037     static uint8_t GetSize( bool zip64 )
0038     {
0039       if( zip64 ) return sizeof( sign ) + 3 * sizeof( uint64_t );
0040       return sizeof( sign ) + 3 * sizeof( uint32_t );
0041     }
0042 
0043     static const uint16_t flag = 1 << 3; //< bit 3 is set
0044     static const uint32_t sign = 0x08074b50;
0045   };
0046 }
0047 
0048 #endif /* SRC_XRDZIP_XRDZIPDATADESCRIPTOR_HH_ */