ArchiveDirectory

Base class for archive directories. Provides common subdirectory and file management.

Constructors

this
this()

Default constructor for ArchiveDirectories. Used to create the root archive. Note: Do not use without a subsequent call to *at least* .path = "path".

this
this(string mypath)
this(string[] parts)

Constructs a new ArchiveDirectory with the given path name.

Members

Aliases

Directory
alias Directory = Policy.DirectoryImpl

Alias for referencing the correct Directory class in the Policy.

File
alias File = Policy.FileImpl

Alias for referencing the correct File class in the Policy.

Functions

directoriesOpApply
int directoriesOpApply(int delegate(ref Directory) dg)

opApply method used for directory iteration.

filesOpApply
int filesOpApply(int delegate(ref File) dg)

opApply method used for file iteration.

membersOpApply
int membersOpApply(int delegate(ref ArchiveMember) dg)

opApply method for member iteration.

Variables

directories
Directory[string] directories;

Subdirectories in this directory. Allows access to directories during manual recursion of the Directory structure.

files
File[string] files;

Files in this directory. Allows access to files during manual recursion of the Directory structure.

Inherited Members

From ArchiveMember

isDirectory
bool isDirectory [@property getter]
isFile
bool isFile [@property getter]
name
string name [@property getter]

Gets the final element in the path of this member. e.g. for the path "a/b/c/e/fg.txt" the result is "fg.txt"

name
string name [@property setter]

Sets the final element in the path of this member. e.g. for the path "a/b/c/e/fg.txt" the changed path part will be "fg.txt" Warning: Do not use this property while this member is currently part of an archive.

path
string path [@property getter]

Gets the path of this member.

path
string path [@property setter]

Sets the path of this member. Warning: Do not use this property while this member is currently part of an archive.

Meta