Table of Contents

Class File

Namespace
GtkSource
Assembly
GtkSource-5.dll
public class File : Object, IDisposable, NativeObject, GTypeProvider, InstanceFactory
Inheritance
File
Implements
Inherited Members

Constructors

File(params ConstructArgument[])

[Obsolete("Regular C# constructors on native classes will be removed in a future version. Please see the linked documentation for more details. It contains scenarios and possible solutions to prepare for the upcoming changes.", DiagnosticId = "GirCore1007", UrlFormat = "https://gircore.github.io/docs/integration/diagnostic/1007.html")]
public File(params ConstructArgument[] constructArguments)

Parameters

constructArguments ConstructArgument[]

File(CreationData)

[Obsolete("This constructor is a workaround to keep legacy APIs alive. Do not use it.")]
protected File(CreationData data)

Parameters

data CreationData

File(FileHandle)

protected File(FileHandle handle)

Parameters

handle FileHandle

Fields

CompressionTypePropertyDefinition

public static readonly Property<CompressionType, File> CompressionTypePropertyDefinition

Field Value

Property<CompressionType, File>

EncodingPropertyDefinition

public static readonly Property<Encoding, File> EncodingPropertyDefinition

Field Value

Property<Encoding, File>

LocationPropertyDefinition

public static readonly Property<File, File> LocationPropertyDefinition

Field Value

Property<File, File>

NewlineTypePropertyDefinition

public static readonly Property<NewlineType, File> NewlineTypePropertyDefinition

Field Value

Property<NewlineType, File>

ReadOnlyPropertyDefinition

public static readonly Property<bool, File> ReadOnlyPropertyDefinition

Field Value

Property<bool, File>

Properties

CompressionType

public CompressionType CompressionType { get; }

Property Value

CompressionType

Encoding

public Encoding Encoding { get; }

Property Value

Encoding

Location

public File Location { get; set; }

Property Value

File

NewlineType

public NewlineType NewlineType { get; }

Property Value

NewlineType

ReadOnly

public bool ReadOnly { get; }

Property Value

bool

Methods

CheckFileOnDisk()

public void CheckFileOnDisk()

GetCompressionType()

public CompressionType GetCompressionType()

Returns

CompressionType

GetEncoding()

public Encoding GetEncoding()

Returns

Encoding

GetGType()

public static Type GetGType()

Returns

Type

GetLocation()

public File GetLocation()

Returns

File

GetNewlineType()

public NewlineType GetNewlineType()

Returns

NewlineType

IsDeleted()

public bool IsDeleted()

Returns

bool

IsExternallyModified()

public bool IsExternallyModified()

Returns

bool

IsLocal()

public bool IsLocal()

Returns

bool

IsReadonly()

public bool IsReadonly()

Returns

bool

New()

public static File New()

Returns

File

NewFromPointer(nint, bool)

Creates a new managed File instance for a given pointer.

public static File NewFromPointer(nint ptr, bool ownsHandle)

Parameters

ptr nint
ownsHandle bool

Returns

File

NewWithProperties(ConstructArgument[])

Creates a new File and sets the properties specified by the construct arguments.

public static File NewWithProperties(ConstructArgument[] constructArguments)

Parameters

constructArguments ConstructArgument[]

The properties to set.

Returns

File

SetLocation(File?)

public void SetLocation(File? location)

Parameters

location File

SetMountOperationFactory(MountOperationFactory)

public void SetMountOperationFactory(MountOperationFactory callback)

Parameters

callback MountOperationFactory