WindowsFileInfoCommand
Base classes¶
| Name | Children | Inherits |
|---|---|---|
| FileInfoCommand anyenv.os_commands.base Base class for file info commands. |
⋔ Inheritance diagram¶
graph TD
25597700["file_info.WindowsFileInfoCommand"]
3903279879["base.FileInfoCommand"]
925645236["abc.ABC"]
2751680898["builtins.object"]
3903279879 --> 25597700
925645236 --> 3903279879
2751680898 --> 925645236
🛈 DocStrings¶
Bases: FileInfoCommand
Windows file info command implementation.
Source code in src/anyenv/os_commands/file_info.py
create_command
¶
Generate PowerShell file info command.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
path
|
str
|
Path to get information about |
required |
Returns:
| Type | Description |
|---|---|
str
|
The PowerShell command string |
Source code in src/anyenv/os_commands/file_info.py
parse_command
¶
parse_command(output: str, path: str) -> FileInfo
Parse PowerShell output format: name||size||type||mtime.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
output
|
str
|
Raw PowerShell command output |
required |
path
|
str
|
Original path requested |
required |
Returns:
| Type | Description |
|---|---|
FileInfo
|
FileInfo object with parsed information |