Please use resources internally instead of SplFileObject instances. #202

Closed
frankdejonge opened this Issue Jan 23, 2017 · 2 comments

Comments

Projects
None yet
2 participants
@frankdejonge
Member

frankdejonge commented Jan 23, 2017

Issue summary

Due to the need to use SplFileObject instances internally any input it required to be compatible with the restrictions said class puts in them. Every SplFileObject method we call has a function counterpart. The only thing we actually use is the iterative capabilities of the object. This could/should be replaces with an own implementation.

If we accomplish this we achieve a higher level of interoperability, we're able not only to work with local files but also with resources from remote locations, which is, by any definition, simple "the shit".


System informations

Information Description
League\Csv version next
PHP/HHVM version any
OS Platform dna

Standalone code, or other way to reproduce the problem

Try to use the existing package with a resource and weep.

Expected result

More interoperability

Actual result

A sad face because it's not yet at this level of awesomeness.

nyamsprod added a commit that referenced this issue Jan 24, 2017

Adding createFromStream #202
- This commit adds the ability to work with resource stream by
adding a StreamIterator object that mimick SplFileObject and takes
a stream resource as its unique constructor argument. To work
as intended the resource stream needs to be seekable.

nyamsprod added a commit that referenced this issue Jan 24, 2017

Adding createFromStream #202 (#203)
* Adding createFromStream #202

This commit adds the ability to work with resource stream by
adding a `StreamIterator` object that mimick SplFileObject and takes
a stream resource as its unique constructor argument. To work
as intended the resource stream needs to be seekable.
@nyamsprod

This comment has been minimized.

Show comment
Hide comment
@nyamsprod

nyamsprod Jan 24, 2017

Member

This issue is resolved in the master branch ... rejoice my friend as the answer is being review for release

Member

nyamsprod commented Jan 24, 2017

This issue is resolved in the master branch ... rejoice my friend as the answer is being review for release

@nyamsprod nyamsprod closed this Jan 24, 2017

@frankdejonge

This comment has been minimized.

Show comment
Hide comment
@frankdejonge

frankdejonge Jan 24, 2017

Member

/gif party time

Member

frankdejonge commented Jan 24, 2017

/gif party time

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment