Skip to main content

class ImageDirectory

class contree_sdk.sdk.objects.image_fs.ImageDirectory(size, path, uid, gid, mode, mtime, nlink, symlink_to, is_dir, is_regular, is_socket, is_fifo, is_symlink, owner, group, _image, _path)

Attributes

full_path
PurePosixPath
is_file
name
str
is_dir
Literal[True]
size
int
path
str
uid
int
gid
int
mode
int
mtime
int
is_regular
bool
is_socket
bool
is_fifo
bool
owner
str
group
str

Methods

ls()

async def ls(path) -> list[ImageFile | ImageDirectory]
path
default:"''"
returns
list[ImageFile | ImageDirectory]

class ImageDirectorySync

class contree_sdk.sdk.objects.image_fs.ImageDirectorySync(size, path, uid, gid, mode, mtime, nlink, symlink_to, is_dir, is_regular, is_socket, is_fifo, is_symlink, owner, group, _image, _path)

Attributes

full_path
PurePosixPath
is_file
name
str
is_dir
Literal[True]
size
int
path
str
uid
int
gid
int
mode
int
mtime
int
is_regular
bool
is_socket
bool
is_fifo
bool
owner
str
group
str

Methods

ls()

def ls(path) -> list[ImageFileSync | ImageDirectorySync]
path
default:"''"
returns
list[ImageFileSync | ImageDirectorySync]

class ImageFile

class contree_sdk.sdk.objects.image_fs.ImageFile(size, path, uid, gid, mode, mtime, nlink, symlink_to, is_dir, is_regular, is_socket, is_fifo, is_symlink, owner, group, _image, _path)

Attributes

full_path
PurePosixPath
is_file
name
str
is_dir
Literal[False]
size
int
path
str
uid
int
gid
int
mode
int
mtime
int
is_regular
bool
is_socket
bool
is_fifo
bool
owner
str
group
str

Methods

download()

async def download(local_path) -> Path
local_path
default:"None"
returns
Path

read()

async def read() -> bytes
returns
bytes

class ImageFileSync

class contree_sdk.sdk.objects.image_fs.ImageFileSync(size, path, uid, gid, mode, mtime, nlink, symlink_to, is_dir, is_regular, is_socket, is_fifo, is_symlink, owner, group, _image, _path)

Attributes

full_path
PurePosixPath
is_file
name
str
is_dir
Literal[False]
size
int
path
str
uid
int
gid
int
mode
int
mtime
int
is_regular
bool
is_socket
bool
is_fifo
bool
owner
str
group
str

Methods

download()

def download(local_path) -> Path
local_path
default:"None"
returns
Path

read()

def read() -> bytes
returns
bytes