Skip to content

Share

A local SMB share, identified by its immutable name.

Obtained from share or create_share.

Fields

name @ Str

The share name.

Methods

delete()

Deletes the share, invalidating this handle.

info() -> ShareInfo

Reads a fresh snapshot of the share.

update … -> ShareInfo

Updates the supplied fields.

They are applied in comment, maximum-use, descriptor order, so a later failure leaves the earlier changes applied.

Parameters

NameTypeDescription
:comment? (Str | nil) Comment. nil clears it.
:max_uses? (Int | nil) Connection limit. nil is unlimited.
:sec_desc? (security.windows.SecDesc | Bin | Dict[{...}]) Security descriptor, self-relative packet, or declarative descriptor.

Returns

Fresh information for the share.