## org.freedesktop.UDisks2.Partition org.freedesktop.UDisks2.Partition — Block device representing a partition |

## Methods

    SetType  (IN  s     type,
              IN  a{sv} options);
    SetName  (IN  s     name,
              IN  a{sv} options);
    SetFlags (IN  t     flags,
              IN  a{sv} options);
    Delete   (IN  a{sv} options);

## Properties

    Number       readable   u
    Type         readable   s
    Flags        readable   t
    Offset       readable   t
    Size         readable   t
    Name         readable   s
    UUID         readable   s
    Table        readable   o
    IsContainer  readable   b
    IsContained  readable   b

## Description

This interface is used for org.freedesktop.UDisks2.Block devices that represent entries in a partition table.

## Method Details

### The SetType() method

    SetType (IN  s     type,
             IN  a{sv} options);

Sets the partition type. See the "Type" property for a description of known partition types.

`IN s `type``: | New type to set.
`IN a{sv} `options``: | Options (currently unused except for standard options).

### The SetName() method

    SetName (IN  s     name,
             IN  a{sv} options);

Sets the partition name.

`IN s `name``: | New name to set.
`IN a{sv} `options``: | Options (currently unused except for standard options).

### The SetFlags() method

    SetFlags (IN  t     flags,
              IN  a{sv} options);

Sets the partition flags. See the "Flags" property for a description of known flags.

`IN t `flags``: | New flags to set.
`IN a{sv} `options``: | Options (currently unused except for standard options).

### The Delete() method

    Delete (IN  a{sv} options);

Deletes the partition.

`IN a{sv} `options``: | Options (currently unused except for standard options).

## Property Details

### The "Number" property

    Number  readable   u

The number of the partition in the partition table.

### The "Type" property

    Type  readable   s

The type of the partition.

For `dos` partition tables, this string is a hexadecimal number e.g. `0x83` or `0xfd`. For `gpt` partition tables this is the UUID e.g. `ebd0a0a2-b9e5-4433-87c0-68b6b72699c7`.

### The "Flags" property

    Flags  readable   t

Flags describing the partition.

Known flags for `dos` partitions include:

Bit 7 | The partition is marked as bootable

Known flags for `gpt` partitions include:

Bit 0 | System partition
Bit 2 | Legacy BIOS Bootable
Bit 60 | Read-only
Bit 62 | Hidden
Bit 63 | Do not automount

### The "Offset" property

    Offset  readable   t

Offset of partition, in bytes.

### The "Size" property

    Size  readable   t

Size of partition, in bytes.

### The "Name" property

    Name  readable   s

Label of partition or blank if not supported or unknown.

### The "UUID" property

    UUID  readable   s

The UUID of the partition or blank if not supported or unknown.

### The "Table" property

    Table  readable   o

The object path of the org.freedesktop.UDisks2.PartitionTable object that the partition entry belongs to.

### The "IsContainer" property

    IsContainer  readable   b

Set to `TRUE` if the partition itself is a container for other partitions.

For example, for `dos` partition tables, this applies to socalled extended partition (partitions of type `0x05`, `0x0f` or `0x85`) containing socalled logical partitions.

### The "IsContained" property

    IsContained  readable   b

Set to `TRUE` of the partition is contained in another partition. See the "IsContainer" property for more information.