Table of Contents

Class SgaEntry

Namespace
OpenCompote.SGA
Assembly
OpenCompote.dll

Represents an item in the SGA archive like file or folder.

public abstract class SgaEntry
Inheritance
SgaEntry
Derived
Inherited Members

Properties

Drive

Gets the SGA drive that the entry belongs to.

public SgaDrive? Drive { get; }

Property Value

SgaDrive

Name

Gets or sets the name of the entry in the SGA archive. Entry name must be a valid sga name. For more info see File/Folder naming restrictions.

public string Name { get; set; }

Property Value

string

Exceptions

InvalidOperationException

The SGA archive for this folder was open in readonly mode.

ObjectDisposedException

The SGA archive for this folder has been disposed, or this entry is deleted.

ArgumentException

The value is not a valid sga entry name, or entry with this name already exists in the parent folder.

ArgumentNullException

The value is null.

Parent

Gets the parent folder of this entry or null if entry is directly inside a drive or the entry is deleted.

public SgaFolder? Parent { get; }

Property Value

SgaFolder

Path

Gets the fully qualified path of the entry in the SGA drive.

public string Path { get; }

Property Value

string

Exceptions

ObjectDisposedException

The SGA archive for this folder has been disposed, or this entry is deleted.

Methods

Delete()

Deletes the entry and all its sub entries from the archive.

public void Delete()

Exceptions

InvalidOperationException

The parent SgaArchive for this entry was opened in readonly mode.

ObjectDisposedException

The parent SgaArchive for this entry was already closed or current entry is already deleted.

IOException

If current entry is SgaFile then this file is currently open for editing and cannot be deleted or if current entry is SgaFolder then this folder contains one or more opened files.

ThrowIfDeleted()

protected void ThrowIfDeleted()