/usr/lib/python2.7/dist-packages/IcePatch2/FileInfo_ice.py is in python-zeroc-ice 3.7.0-5.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 | # -*- coding: utf-8 -*-
# **********************************************************************
#
# Copyright (c) 2003-2017 ZeroC, Inc. All rights reserved.
#
# This copy of Ice is licensed to you under the terms described in the
# ICE_LICENSE file included in this distribution.
#
# **********************************************************************
#
# Ice version 3.7.0
#
# <auto-generated>
#
# Generated from file `FileInfo.ice'
#
# Warning: do not edit this file.
#
# </auto-generated>
#
from sys import version_info as _version_info_
import Ice, IcePy
import Ice.BuiltinSequences_ice
# Included module Ice
_M_Ice = Ice.openModule('Ice')
# Start of module IcePatch2
_M_IcePatch2 = Ice.openModule('IcePatch2')
__name__ = 'IcePatch2'
if 'FileInfo' not in _M_IcePatch2.__dict__:
_M_IcePatch2.FileInfo = Ice.createTempClass()
class FileInfo(object):
"""
Basic information about a single file.
Members:
path -- The pathname.
checksum -- The SHA-1 checksum of the file.
size -- The size of the compressed file in number of bytes.
executable -- The executable flag.
"""
def __init__(self, path='', checksum=None, size=0, executable=False):
self.path = path
self.checksum = checksum
self.size = size
self.executable = executable
def __hash__(self):
_h = 0
_h = 5 * _h + Ice.getHash(self.path)
if self.checksum:
for _i0 in self.checksum:
_h = 5 * _h + Ice.getHash(_i0)
_h = 5 * _h + Ice.getHash(self.size)
_h = 5 * _h + Ice.getHash(self.executable)
return _h % 0x7fffffff
def __compare(self, other):
if other is None:
return 1
elif not isinstance(other, _M_IcePatch2.FileInfo):
return NotImplemented
else:
if self.path is None or other.path is None:
if self.path != other.path:
return (-1 if self.path is None else 1)
else:
if self.path < other.path:
return -1
elif self.path > other.path:
return 1
if self.checksum is None or other.checksum is None:
if self.checksum != other.checksum:
return (-1 if self.checksum is None else 1)
else:
if self.checksum < other.checksum:
return -1
elif self.checksum > other.checksum:
return 1
if self.size is None or other.size is None:
if self.size != other.size:
return (-1 if self.size is None else 1)
else:
if self.size < other.size:
return -1
elif self.size > other.size:
return 1
if self.executable is None or other.executable is None:
if self.executable != other.executable:
return (-1 if self.executable is None else 1)
else:
if self.executable < other.executable:
return -1
elif self.executable > other.executable:
return 1
return 0
def __lt__(self, other):
r = self.__compare(other)
if r is NotImplemented:
return r
else:
return r < 0
def __le__(self, other):
r = self.__compare(other)
if r is NotImplemented:
return r
else:
return r <= 0
def __gt__(self, other):
r = self.__compare(other)
if r is NotImplemented:
return r
else:
return r > 0
def __ge__(self, other):
r = self.__compare(other)
if r is NotImplemented:
return r
else:
return r >= 0
def __eq__(self, other):
r = self.__compare(other)
if r is NotImplemented:
return r
else:
return r == 0
def __ne__(self, other):
r = self.__compare(other)
if r is NotImplemented:
return r
else:
return r != 0
def __str__(self):
return IcePy.stringify(self, _M_IcePatch2._t_FileInfo)
__repr__ = __str__
_M_IcePatch2._t_FileInfo = IcePy.defineStruct('::IcePatch2::FileInfo', FileInfo, (), (
('path', (), IcePy._t_string),
('checksum', (), _M_Ice._t_ByteSeq),
('size', (), IcePy._t_int),
('executable', (), IcePy._t_bool)
))
_M_IcePatch2.FileInfo = FileInfo
del FileInfo
if '_t_FileInfoSeq' not in _M_IcePatch2.__dict__:
_M_IcePatch2._t_FileInfoSeq = IcePy.defineSequence('::IcePatch2::FileInfoSeq', (), _M_IcePatch2._t_FileInfo)
if 'LargeFileInfo' not in _M_IcePatch2.__dict__:
_M_IcePatch2.LargeFileInfo = Ice.createTempClass()
class LargeFileInfo(object):
"""
Basic information about a single file.
Members:
path -- The pathname.
checksum -- The SHA-1 checksum of the file.
size -- The size of the compressed file in number of bytes.
executable -- The executable flag.
"""
def __init__(self, path='', checksum=None, size=0, executable=False):
self.path = path
self.checksum = checksum
self.size = size
self.executable = executable
def __hash__(self):
_h = 0
_h = 5 * _h + Ice.getHash(self.path)
if self.checksum:
for _i0 in self.checksum:
_h = 5 * _h + Ice.getHash(_i0)
_h = 5 * _h + Ice.getHash(self.size)
_h = 5 * _h + Ice.getHash(self.executable)
return _h % 0x7fffffff
def __compare(self, other):
if other is None:
return 1
elif not isinstance(other, _M_IcePatch2.LargeFileInfo):
return NotImplemented
else:
if self.path is None or other.path is None:
if self.path != other.path:
return (-1 if self.path is None else 1)
else:
if self.path < other.path:
return -1
elif self.path > other.path:
return 1
if self.checksum is None or other.checksum is None:
if self.checksum != other.checksum:
return (-1 if self.checksum is None else 1)
else:
if self.checksum < other.checksum:
return -1
elif self.checksum > other.checksum:
return 1
if self.size is None or other.size is None:
if self.size != other.size:
return (-1 if self.size is None else 1)
else:
if self.size < other.size:
return -1
elif self.size > other.size:
return 1
if self.executable is None or other.executable is None:
if self.executable != other.executable:
return (-1 if self.executable is None else 1)
else:
if self.executable < other.executable:
return -1
elif self.executable > other.executable:
return 1
return 0
def __lt__(self, other):
r = self.__compare(other)
if r is NotImplemented:
return r
else:
return r < 0
def __le__(self, other):
r = self.__compare(other)
if r is NotImplemented:
return r
else:
return r <= 0
def __gt__(self, other):
r = self.__compare(other)
if r is NotImplemented:
return r
else:
return r > 0
def __ge__(self, other):
r = self.__compare(other)
if r is NotImplemented:
return r
else:
return r >= 0
def __eq__(self, other):
r = self.__compare(other)
if r is NotImplemented:
return r
else:
return r == 0
def __ne__(self, other):
r = self.__compare(other)
if r is NotImplemented:
return r
else:
return r != 0
def __str__(self):
return IcePy.stringify(self, _M_IcePatch2._t_LargeFileInfo)
__repr__ = __str__
_M_IcePatch2._t_LargeFileInfo = IcePy.defineStruct('::IcePatch2::LargeFileInfo', LargeFileInfo, (), (
('path', (), IcePy._t_string),
('checksum', (), _M_Ice._t_ByteSeq),
('size', (), IcePy._t_long),
('executable', (), IcePy._t_bool)
))
_M_IcePatch2.LargeFileInfo = LargeFileInfo
del LargeFileInfo
if '_t_LargeFileInfoSeq' not in _M_IcePatch2.__dict__:
_M_IcePatch2._t_LargeFileInfoSeq = IcePy.defineSequence('::IcePatch2::LargeFileInfoSeq', (), _M_IcePatch2._t_LargeFileInfo)
# End of module IcePatch2
Ice.sliceChecksums["::IcePatch2::FileInfo"] = "4c71622889c19c7d3b5ef8210245"
Ice.sliceChecksums["::IcePatch2::FileInfoSeq"] = "892945a7a7bfb532f6148c4be9889bd"
Ice.sliceChecksums["::IcePatch2::LargeFileInfo"] = "c711b1cd93bfe8cab428a3201e0f291"
Ice.sliceChecksums["::IcePatch2::LargeFileInfoSeq"] = "96e1aec0272b42f09289701462bb5921"
|