MCPcopy
hub / github.com/borgbackup/borg / FileSize

Class FileSize

src/borg/helpers/parseformat.py:432–439  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

430
431
432class FileSize(int):
433 def __new__(cls, value, iec=False):
434 obj = int.__new__(cls, value)
435 obj.iec = iec
436 return obj
437
438 def __format__(self, format_spec):
439 return format_file_size(int(self), iec=self.iec).__format__(format_spec)
440
441
442def parse_file_size(s):

Callers 1

as_dictMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected