Skip to content

FileInfoCommand

Sub classes

Name Children Inherits
UnixFileInfoCommand
anyenv.os_commands.file_info
Unix/Linux file info command implementation using ls -la.
    MacOSFileInfoCommand
    anyenv.os_commands.file_info
    macOS file info command implementation using ls -la.
      WindowsFileInfoCommand
      anyenv.os_commands.file_info
      Windows file info command implementation.

        Base classes

        Name Children Inherits
        ABC
        abc
        Helper class that provides a standard way to create an ABC using

        ⋔ Inheritance diagram

        graph TD
          3903279879["base.FileInfoCommand"]
          925645236["abc.ABC"]
          2751680898["builtins.object"]
          925645236 --> 3903279879
          2751680898 --> 925645236

        🛈 DocStrings

        Bases: ABC

        Base class for file info commands.

        Source code in src/anyenv/os_commands/base.py
        class FileInfoCommand(ABC):
            """Base class for file info commands."""
        
            @abstractmethod
            def create_command(self, path: str) -> str:
                """Generate file info command."""
        
            @abstractmethod
            def parse_command(self, output: str, path: str) -> FileInfo:
                """Parse file info output."""
        

        create_command abstractmethod

        create_command(path: str) -> str
        

        Generate file info command.

        Source code in src/anyenv/os_commands/base.py
        @abstractmethod
        def create_command(self, path: str) -> str:
            """Generate file info command."""
        

        parse_command abstractmethod

        parse_command(output: str, path: str) -> FileInfo
        

        Parse file info output.

        Source code in src/anyenv/os_commands/base.py
        @abstractmethod
        def parse_command(self, output: str, path: str) -> FileInfo:
            """Parse file info output."""
        

        :fa-brands-github: Show source on GitHub