Comments (11)
Pull request initialized .
from aura.signal.
Hey man, can you attach a test case for this?
from aura.signal.
@pmjones also I guess that pull request was too old, so we may want to test the same again.
I will try to write a test case. But I may want your help, lets discuss tonight at irc if I didn't finish it :) .
from aura.signal.
@pmjones See https://github.com/auraphp/Aura.Signal/blob/master/src/Aura/Signal/Manager.php#L185 , you have already mentioned about the return type ResultCollection
The results from each of the Handler objects.
But forgot to return it . So in the above example the results is not having an object of it, hence the error and ie the pull request #3 .
About the test case , I wonder for which one we neeed . About the clone one ?
from aura.signal.
Another Question is regarding the use of
// clone a new result collection
$this->results = clone $this->result_collection;
in send() , do we need it in constructor then ?
$this->results = clone $this->result_collection;
from aura.signal.
I don't think so; the idea is that the manager will have to deal with lots of send()ing, and it's easiest to reuse a clone of the initial empty collection.
from aura.signal.
ok for clone in send() . What about in constructor ? Or does that answers all ?
from aura.signal.
The constructor already has a ResultCollection param. Am I missing what you're getting at?
from aura.signal.
My query is regarding https://github.com/auraphp/Aura.Signal/blob/master/src/Aura/Signal/Manager.php#L114 . Do we need that there for we already have the clone in send() .
from aura.signal.
But we also have getResults(), which needs to return a ResultCollection, even if you haven't called send() yet.
from aura.signal.
Yup that make sense :) . Sorry for the long conversation :D .
from aura.signal.
Related Issues (3)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from aura.signal.