How to use splfileinfo and splfileobject?

Hi cake, let me know please how to use this object splfileinfo and splfileobject? Actually I am still using Folder() File() Api for directory and files system but cakephp official documentation highlight that it will be deprecated and use Splfileobject but does not give any code example, so please just show me coding example how to use Folder and File Api in next cakephp version I mean how to use use SplFileInfo object in current project
Thank you

Its the PHP built in File classes and functionality

Not really sure what we should re-document if everything is already documented on