Nautilus.FileInfo
Description: Reference for Nautilus.FileInfo

### Interface

# NautilusFileInfo

#### Description

    interface Nautilus.FileInfo : GObject.Object

No description available.

#### Prerequisite

In order to implement FileInfo, your type must inherit from`GObject`.

#### Functions

###### nautilus_file_info_create

No description available.

###### nautilus_file_info_create_for_uri

No description available.

###### nautilus_file_info_list_copy

No description available.

###### nautilus_file_info_list_free

No description available.

###### nautilus_file_info_lookup

No description available.

###### nautilus_file_info_lookup_for_uri

No description available.

#### Instance methods

###### nautilus_file_info_add_emblem

No description available.

###### nautilus_file_info_add_string_attribute

No description available.

###### nautilus_file_info_can_write

No description available.

###### nautilus_file_info_get_activation_uri

No description available.

###### nautilus_file_info_get_file_type

No description available.

###### nautilus_file_info_get_location

No description available.

###### nautilus_file_info_get_mime_type

No description available.

###### nautilus_file_info_get_mount

No description available.

###### nautilus_file_info_get_name

No description available.

###### nautilus_file_info_get_parent_info

It’s not safe to call this recursively multiple times, as it works only for files already cached by Nautilus.

###### nautilus_file_info_get_parent_location

No description available.

###### nautilus_file_info_get_parent_uri

No description available.

###### nautilus_file_info_get_string_attribute

No description available.

###### nautilus_file_info_get_uri

No description available.

###### nautilus_file_info_get_uri_scheme

No description available.

###### nautilus_file_info_invalidate_extension_info

No description available.

###### nautilus_file_info_is_directory

No description available.

###### nautilus_file_info_is_gone

No description available.

###### nautilus_file_info_is_mime_type

No description available.

#### Interface structure

    struct NautilusFileInfoInterface {
      GTypeInterface g_iface;
      gboolean (* is_gone) (
        NautilusFileInfo* file_info
      );
      char* (* get_name) (
        NautilusFileInfo* file_info
      );
      char* (* get_uri) (
        NautilusFileInfo* file_info
      );
      char* (* get_parent_uri) (
        NautilusFileInfo* file_info
      );
      char* (* get_uri_scheme) (
        NautilusFileInfo* file_info
      );
      char* (* get_mime_type) (
        NautilusFileInfo* file_info
      );
      gboolean (* is_mime_type) (
        NautilusFileInfo* file_info,
        const char* mime_type
      );
      gboolean (* is_directory) (
        NautilusFileInfo* file_info
      );
      void (* add_emblem) (
        NautilusFileInfo* file_info,
        const char* emblem_name
      );
      char* (* get_string_attribute) (
        NautilusFileInfo* file_info,
        const char* attribute_name
      );
      void (* add_string_attribute) (
        NautilusFileInfo* file_info,
        const char* attribute_name,
        const char* value
      );
      void (* invalidate_extension_info) (
        NautilusFileInfo* file_info
      );
      char* (* get_activation_uri) (
        NautilusFileInfo* file_info
      );
      GFileType (* get_file_type) (
        NautilusFileInfo* file_info
      );
      GFile* (* get_location) (
        NautilusFileInfo* file_info
      );
      GFile* (* get_parent_location) (
        NautilusFileInfo* file_info
      );
      NautilusFileInfo* (* get_parent_info) (
        NautilusFileInfo* file_info
      );
      GMount* (* get_mount) (
        NautilusFileInfo* file_info
      );
      gboolean (* can_write) (
        NautilusFileInfo* file_info
      );

    }

Interface for extensions to provide additional menu items.

###### Interface members

`g_iface` |
    GTypeInterface
| The parent interface.
`is_gone` |
    gboolean (* is_gone) (
        NautilusFileInfo* file_info
      )
| Returns whether the file info is gone. See `nautilus_file_info_is_gone()` for details.
`get_name` |
    char* (* get_name) (
        NautilusFileInfo* file_info
      )
| Returns the file name as a string. See `nautilus_file_info_get_name()` for details.
`get_uri` |
    char* (* get_uri) (
        NautilusFileInfo* file_info
      )
| Returns the file URI as a string. See `nautilus_file_info_get_uri()` for details.
`get_parent_uri` |
    char* (* get_parent_uri) (
        NautilusFileInfo* file_info
      )
| Returns the file parent URI as a string. See `nautilus_file_info_get_parent_uri()` for details.
`get_uri_scheme` |
    char* (* get_uri_scheme) (
        NautilusFileInfo* file_info
      )
| Returns the file URI scheme as a string. See `nautilus_file_info_get_uri_scheme()` for details.
`get_mime_type` |
    char* (* get_mime_type) (
        NautilusFileInfo* file_info
      )
| Returns the file mime type as a string. See `nautilus_file_info_get_mime_type()` for details.
`is_mime_type` |
    gboolean (* is_mime_type) (
        NautilusFileInfo* file_info,
        const char* mime_type
      )
| Returns whether the file is the given mime type. See `nautilus_file_info_is_mime_type()` for details.
`is_directory` |
    gboolean (* is_directory) (
        NautilusFileInfo* file_info
      )
| Returns whether the file is a directory. See `nautilus_file_info_is_directory()` for details.
`add_emblem` |
    void (* add_emblem) (
        NautilusFileInfo* file_info,
        const char* emblem_name
      )
| Adds an emblem to this file. See `nautilus_file_info_add_emblem()` for details.
`get_string_attribute` |
    char* (* get_string_attribute) (
        NautilusFileInfo* file_info,
        const char* attribute_name
      )
| Returns the specified file attribute as a string. See `nautilus_file_info_get_string_attribute()` for details.
`add_string_attribute` |
    void (* add_string_attribute) (
        NautilusFileInfo* file_info,
        const char* attribute_name,
        const char* value
      )
| Sets the specified string file attribute value. See `nautilus_file_info_add_string_attribute()` for details.
`invalidate_extension_info` |
    void (* invalidate_extension_info) (
        NautilusFileInfo* file_info
      )
| Invalidates information of the file provided by extensions. See `nautilus_file_info_invalidate_extension_info()` for details.
`get_activation_uri` |
    char* (* get_activation_uri) (
        NautilusFileInfo* file_info
      )
| Returns the file activation URI as a string. See `nautilus_file_info_get_activation_uri()` for details.
`get_file_type` |
    GFileType (* get_file_type) (
        NautilusFileInfo* file_info
      )
| Returns the file type. See `nautilus_file_info_get_file_type()` for details.
`get_location` |
    GFile* (* get_location) (
        NautilusFileInfo* file_info
      )
| Returns the file location as a `GFile`. See `nautilus_file_info_get_location()` for details.
`get_parent_location` |
    GFile* (* get_parent_location) (
        NautilusFileInfo* file_info
      )
| Returns the file parent location as a `GFile`. See `nautilus_file_info_get_parent_location()` for details.
`get_parent_info` |
    NautilusFileInfo* (* get_parent_info) (
        NautilusFileInfo* file_info
      )
| Returns the file parent `NautilusFileInfo`. See `nautilus_file_info_get_parent_info()` for details.
`get_mount` |
    GMount* (* get_mount) (
        NautilusFileInfo* file_info
      )
| Returns the file mount as a `GMount`. See `nautilus_file_info_get_mount()` for details.
`can_write` |
    gboolean (* can_write) (
        NautilusFileInfo* file_info
      )
| Returns whether the file is writable. See `nautilus_file_info_can_write()` for details.

#### Virtual methods

###### Nautilus.FileInfo.add_emblem

Adds an emblem to this file. See `nautilus_file_info_add_emblem()` for details.

###### Nautilus.FileInfo.add_string_attribute

Sets the specified string file attribute value. See `nautilus_file_info_add_string_attribute()` for details.

###### Nautilus.FileInfo.can_write

Returns whether the file is writable. See `nautilus_file_info_can_write()` for details.

###### Nautilus.FileInfo.get_activation_uri

Returns the file activation URI as a string. See `nautilus_file_info_get_activation_uri()` for details.

###### Nautilus.FileInfo.get_file_type

Returns the file type. See `nautilus_file_info_get_file_type()` for details.

###### Nautilus.FileInfo.get_location

Returns the file location as a `GFile`. See `nautilus_file_info_get_location()` for details.

###### Nautilus.FileInfo.get_mime_type

Returns the file mime type as a string. See `nautilus_file_info_get_mime_type()` for details.

###### Nautilus.FileInfo.get_mount

Returns the file mount as a `GMount`. See `nautilus_file_info_get_mount()` for details.

###### Nautilus.FileInfo.get_name

Returns the file name as a string. See `nautilus_file_info_get_name()` for details.

###### Nautilus.FileInfo.get_parent_info

It’s not safe to call this recursively multiple times, as it works only for files already cached by Nautilus.

###### Nautilus.FileInfo.get_parent_location

Returns the file parent location as a `GFile`. See `nautilus_file_info_get_parent_location()` for details.

###### Nautilus.FileInfo.get_parent_uri

Returns the file parent URI as a string. See `nautilus_file_info_get_parent_uri()` for details.

###### Nautilus.FileInfo.get_string_attribute

Returns the specified file attribute as a string. See `nautilus_file_info_get_string_attribute()` for details.

###### Nautilus.FileInfo.get_uri

Returns the file URI as a string. See `nautilus_file_info_get_uri()` for details.

###### Nautilus.FileInfo.get_uri_scheme

Returns the file URI scheme as a string. See `nautilus_file_info_get_uri_scheme()` for details.

###### Nautilus.FileInfo.invalidate_extension_info

Invalidates information of the file provided by extensions. See `nautilus_file_info_invalidate_extension_info()` for details.

###### Nautilus.FileInfo.is_directory

Returns whether the file is a directory. See `nautilus_file_info_is_directory()` for details.

###### Nautilus.FileInfo.is_gone

Returns whether the file info is gone. See `nautilus_file_info_is_gone()` for details.

###### Nautilus.FileInfo.is_mime_type

Returns whether the file is the given mime type. See `nautilus_file_info_is_mime_type()` for details.