eloquent/pathogen API
Interface

Eloquent\Pathogen\Windows\AbsoluteWindowsPathInterface

interface AbsoluteWindowsPathInterface implements AbsoluteFileSystemPathInterface, WindowsPathInterface

The interface implemented by absolute Windows paths.

Methods

string|null drive()

Get this path's drive specifier.

from WindowsPathInterface
boolean hasDrive()

Determine whether this path has a drive specifier.

from WindowsPathInterface
boolean matchesDrive(string|null $drive)

Returns true if this path's drive specifier matches the supplied drive specifier.

from WindowsPathInterface
boolean matchesDriveOrNull(string|null $drive)

Returns true if this path's drive specifier matches the supplied drive specifier, or if either drive specifier is null.

from WindowsPathInterface
string|null joinDrive($drive)

Joins the supplied drive specifier to this path.

from WindowsPathInterface

Details

in WindowsPathInterface at line 29
public string|null drive()

Get this path's drive specifier.

Absolute Windows paths always have a drive specifier, and will never return null for this method.

Return Value

string|null The drive specifier, or null if this path does not have a drive specifier.

in WindowsPathInterface at line 39
public boolean hasDrive()

Determine whether this path has a drive specifier.

Absolute Windows paths always have a drive specifier, and will always return true for this method.

Return Value

boolean True is this path has a drive specifier.

in WindowsPathInterface at line 51
public boolean matchesDrive(string|null $drive)

Returns true if this path's drive specifier matches the supplied drive specifier.

This method is not case sensitive.

Parameters

string|null $drive The driver specifier to compare to.

Return Value

boolean True if the drive specifiers match.

in WindowsPathInterface at line 63
public boolean matchesDriveOrNull(string|null $drive)

Returns true if this path's drive specifier matches the supplied drive specifier, or if either drive specifier is null.

This method is not case sensitive.

Parameters

string|null $drive The driver specifier to compare to.

Return Value

boolean True if the drive specifiers match, or either drive specifier is null.

in WindowsPathInterface at line 72
public string|null joinDrive($drive)

Joins the supplied drive specifier to this path.

Parameters

$drive

Return Value

string|null $drive The drive specifier to use, or null to remove the drive specifier.