kenahoo / Path-Class

Cross-platform path specification manipulation
http://search.cpan.org/dist/Path-Class/
15 stars 28 forks source link

Add an as_uri method #27

Open robrwo opened 10 years ago

robrwo commented 10 years ago

This patch adds an as_uri method that returns a URI::file object, along with some rudimentary tests.

It does not support file URIs for other operating systems (such as Windows).

kenahoo commented 10 years ago

Thanks. What happens on Windows if you don't set $^O = "Unix"?

robrwo commented 10 years ago

@kenahoo I'm not sure. I think it should get the OS from the object (if it can) and pass that the URI::file.

I also realise that I forgot to add POD for the method.

robrwo commented 10 years ago

@kenahoo I've added some tests for Win32 as well as POD.