IO
ErrorsCollection

IO

Synthesised documentation from type/IO/Path type/IO/Pipe type/Dateish type/IO/Notification/Change type/Distribution/Resource type/IO/Handle type/IO/Special type/Cool type/IO/CatHandle

From type/IO/Path

See Original text in context

method IO(IO::Path:D: --> IO::Path)

Returns the invocant.

From type/IO/Pipe

See Original text in context

method IO(IO::Pipe: --> IO::Path:U)

Returns an IO::Path type object.

From type/Dateish

See Original text in context

method IO(Dateish:D: --> IO::Path:D)

Returns an IO::Path object representing the stringified value of the Dateish object:

Date.today.IO.say;   # OUTPUT: «"2016-10-03".IO␤» 
DateTime.now.IO.say# OUTPUT: «"2016-10-03T11:14:47.977994-04:00".IO␤»

PORTABILITY NOTE: some operating systems (e.g. Windows) do not permit colons (:) in filenames, which would be present in IO::Path created from a DateTime object.

From type/IO/Notification/Change

See Original text in context

Returns a handle of the file that's being watched.

From type/Distribution/Resource

See Original text in context

method IO()

Returns the corresponding resource as an IO::Path, which can effectively be used as such.

From type/IO/Handle

See Original text in context

method IO(IO::Handle:D:)

Alias for .path

From type/IO/Special

See Original text in context

method IO(IO::Special:D: --> IO::Special)

Returns the invocant.

say $*IN.path.IO.what;  # OUTPUT: «<STDIN>␤» 
say $*IN.path.what;     # OUTPUT: «<STDIN>␤»

From type/Cool

See Original text in context

method IO(--> IO::Path:D)

Coerces the invocant to IO::Path.

.say for '.'.IO.dir;        # gives a directory listing 

From type/IO/CatHandle

See Original text in context

method IO(IO::CatHandle:D:)

Alias for .path