ConvertableDirectoryPath Class

Summary

Represents a DirectoryPath that can be easily converted. To get the underlying : ConvertableDirectoryPath convertable = Directory("./root"); DirectoryPath path = (DirectoryPath)convertable; To combine two directories: ConvertableDirectoryPath path = Directory("./root") + Directory("other"); To combine a directory with a file: ConvertableFilePath path = Directory("./root") + File("other.txt");
Namespace
Cake.Common.IO.Paths
Base Types
  • object
graph TD Base0["object"]-->Type Type["ConvertableDirectoryPath"] class Type type-node

Syntax

public sealed class ConvertableDirectoryPath

Properties

Name Value Summary
Path DirectoryPath
Gets the path.

Methods

Name Value Summary
ToString() string
Returns a string that represents this instance.

Operators

Name Value Summary
implicit operator DirectoryPath(ConvertableDirectoryPath) DirectoryPath
implicit operator string(ConvertableDirectoryPath) string
operator +(ConvertableDirectoryPath, ConvertableDirectoryPath) ConvertableDirectoryPath
operator +(ConvertableDirectoryPath, ConvertableFilePath) ConvertableFilePath
operator +(ConvertableDirectoryPath, DirectoryPath) ConvertableDirectoryPath
operator +(ConvertableDirectoryPath, FilePath) ConvertableFilePath

Extension Methods

Name Value Summary
Dump<ConvertableDirectoryPath>() string
Get a basic string representation of specified object.
IsIn<ConvertableDirectoryPath>(ConvertableDirectoryPath[]) bool
Checks if the source is contained in a list
NotNull<ConvertableDirectoryPath>(string) void
Throws an exception if the specified parameter's value is null.
NotNull<ConvertableDirectoryPath>(string) void
Throws an exception if the specified parameter's value is null.
ThrowIfNull<ConvertableDirectoryPath>(string) T
Throws a System.ArgumentNullException if the value is null, otherwise returns the value
ThrowIfNull<ConvertableDirectoryPath>(string, string) T
Throws a System.ArgumentNullException with a specific message if the value is null, otherwise returns the value