예제 #1
0
    def AppliedPartitioning(self) -> ObjPath:
        """The applied partitioning.

        :return: a DBus path or an empty string
        """
        partitioning = self.implementation.applied_partitioning

        if not partitioning:
            return ObjPath("")

        return PartitioningContainer.to_object_path(partitioning)
예제 #2
0
    def AppliedPartitioning(self) -> Str:
        """The applied partitioning.

        An empty string is not a valid object path, so
        the return type has to be a string in this case.

        :return: a DBus path or an empty string
        """
        partitioning = self.implementation.applied_partitioning

        if not partitioning:
            return ""

        return PartitioningContainer.to_object_path(partitioning)
예제 #3
0
    def CreatePartitioning(self, method: Str) -> ObjPath:
        """Create a new partitioning.

        Allowed values:
            AUTOMATIC
            CUSTOM
            MANUAL
            INTERACTIVE
            BLIVET

        :param method: a partitioning method
        :return: a path to a partitioning
        """
        return PartitioningContainer.to_object_path(
            self.implementation.create_partitioning(
                PartitioningMethod(method)))
예제 #4
0
    def CreatePartitioning(self, method: Str) -> ObjPath:
        """Create a new partitioning.

        Create a new partitioning module with its own copy of the current
        storage model. The partitioning module provides an isolated
        playground for scheduling partitioning actions and validating
        the planned partitioning layout. Once the layout is valid, call
        ApplyPartitioning to choose it for the installation.

        Allowed values:
            AUTOMATIC
            CUSTOM
            MANUAL
            INTERACTIVE
            BLIVET

        :param method: a partitioning method
        :return: a path to a partitioning
        """
        return PartitioningContainer.to_object_path(
            self.implementation.create_partitioning(
                PartitioningMethod(method)))