Comment(by niklas@…):
I attached a patch which gets rid of ArrayObject and implements
ArrayAccess.
This will break BC in the constructor. If we are willing to break more BC
and get rid of using AgaviUploadedFile as an array completely, we could
just drop the ArrayAccess specific things and use the OO methods I wrote.
I am going to write tests for the current trunk behavior of
AgaviUploadedFile and attach them to this ticket.
I am going to check how much the constructor change affects other agavi
code and try to patch them aswell.
Cheers,
Niklas
--
Ticket URL: <http://trac.agavi.org/ticket/1287#comment:1>
* cc: niklas@… (added)
--
Ticket URL: <http://trac.agavi.org/ticket/1287#comment:2>
Comment(by david):
There are several problems with this patch:
1. why does it use {{{$this->data}}}? Either use
{{{AgaviParameterHolder}}}, or simply use the properties directly (that
would be the better choice, in my opinion)
2. if it implements {{{ArrayAccess}}}, then why are you replacing
{{{$this->tmp_name}}} with {{{$this->data['tmp_name']}}} and so forth?
3. It doesn't follow the coding standards (e.g. {{{if (…)}}} instead of
{{{if(…)}}})
--
Ticket URL: <http://trac.agavi.org/ticket/1287#comment:3>
Comment(by anonymous):
I attached my last (for now, atleast) attempt to address this problem.
I also made some tests mainly to test the array access and initialization.
--
Ticket URL: <http://trac.agavi.org/ticket/1287#comment:4>
Comment(by sHiShAg0tT):
http://www.bloomquistestateservices.com/homeinsurance.htm home insurance
nkjb
--
Ticket URL: <http://trac.agavi.org/ticket/1287#comment:5>
Comment(by cursedsword):
http://www.loqueotrosven.com/ acomplia 44875 http://www.rap-musiq.com/
acomplia prescription %-( http://www.scribblingscribe.com/ prednisone >:DD
--
Ticket URL: <http://trac.agavi.org/ticket/1287#comment:6>
* status: new => closed
* resolution: => fixed
Comment:
(In [4800]) refactor AgaviUploadedFile, closes #1287
--
Ticket URL: <http://trac.agavi.org/ticket/1287#comment:5>
Comment(by david):
(In [4802]) Use methods to access data for property and array access, refs
#1287
--
Ticket URL: <http://trac.agavi.org/ticket/1287#comment:6>
Comment(by david):
(In [4804]) Optimize index map use to eliminate array_search() calls, refs
#1287
--
Ticket URL: <http://trac.agavi.org/ticket/1287#comment:7>
Comment(by david):
(In [4808]) Only set true as a default for is_uploaded_file field when
fixing up the _FILES array in web request data holders, refs #1287 and
#1412
--
Ticket URL: <http://trac.agavi.org/ticket/1287#comment:8>
Comment(by david):
(In [4842]) fix API doc for ctor, refs #1287
--
Ticket URL: <http://trac.agavi.org/ticket/1287#comment:9>
Comment(by david):
(In [4869]) remove use of tempfile() in AgaviUploadedFile, refs #1412,
#1287 and #1449
--
Ticket URL: <http://trac.agavi.org/ticket/1287#comment:10>