base64_encode
Class info¶
Classes¶
| Name | Children | Inherits |
|---|---|---|
| MacOSBase64EncodeCommand anyenv.os_commands.base64_encode macOS base64 encode command implementation. |
||
| UnixBase64EncodeCommand anyenv.os_commands.base64_encode Unix/Linux base64 encode command implementation. |
||
| WindowsBase64EncodeCommand anyenv.os_commands.base64_encode Windows base64 encode command implementation using PowerShell. |
🛈 DocStrings¶
Base64 encode command implementations for different operating systems.
MacOSBase64EncodeCommand
¶
Bases: Base64EncodeCommand
macOS base64 encode command implementation.
Source code in src/anyenv/os_commands/base64_encode.py
create_command
¶
Generate macOS base64 command.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
path
|
str
|
Path to file to encode |
required |
Returns:
| Type | Description |
|---|---|
str
|
The base64 command string |
Source code in src/anyenv/os_commands/base64_encode.py
parse_command
¶
Parse macOS base64 output.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
output
|
str
|
Raw base64 encoded output |
required |
Returns:
| Type | Description |
|---|---|
bytes
|
Decoded bytes |
Source code in src/anyenv/os_commands/base64_encode.py
UnixBase64EncodeCommand
¶
Bases: Base64EncodeCommand
Unix/Linux base64 encode command implementation.
Source code in src/anyenv/os_commands/base64_encode.py
create_command
¶
Generate Unix base64 command.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
path
|
str
|
Path to file to encode |
required |
Returns:
| Type | Description |
|---|---|
str
|
The base64 command string |
parse_command
¶
Parse Unix base64 output.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
output
|
str
|
Raw base64 encoded output |
required |
Returns:
| Type | Description |
|---|---|
bytes
|
Decoded bytes |
Source code in src/anyenv/os_commands/base64_encode.py
WindowsBase64EncodeCommand
¶
Bases: Base64EncodeCommand
Windows base64 encode command implementation using PowerShell.
Source code in src/anyenv/os_commands/base64_encode.py
create_command
¶
Generate PowerShell base64 encode command.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
path
|
str
|
Path to file to encode |
required |
Returns:
| Type | Description |
|---|---|
str
|
The PowerShell command string |
Source code in src/anyenv/os_commands/base64_encode.py
parse_command
¶
Parse PowerShell base64 output.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
output
|
str
|
Raw base64 encoded output |
required |
Returns:
| Type | Description |
|---|---|
bytes
|
Decoded bytes |