MCPcopy Create free account
hub / github.com/PierreGode/Ragnar / isNormal

Method isNormal

pager_lib/smb/base.py:3091–3098  ·  view source on GitHub ↗

A convenient property to return True if this is a normal file. Note that pysmb defines a normal file as a file entry that is not read-only, not hidden, not system, not archive and not a directory. It ignores other attributes like compression, indexed, sparse, temporary and

(self)

Source from the content-addressed store, hash-verified

3089
3090 @property
3091 def isNormal(self):
3092 """
3093 A convenient property to return True if this is a normal file.
3094
3095 Note that pysmb defines a normal file as a file entry that is not read-only, not hidden, not system, not archive and not a directory.
3096 It ignores other attributes like compression, indexed, sparse, temporary and encryption.
3097 """
3098 return (self.file_attributes==ATTR_NORMAL) or ((self.file_attributes & 0xff)==0)
3099
3100 def __unicode__(self):
3101 return 'Shared file: %s (FileSize:%d bytes, isDirectory:%s)' % ( self.filename, self.file_size, self.isDirectory )

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected