Open Bug 313560 Opened 19 years ago Updated 15 years ago

Create smart "Data Manager" for ChatZilla objects

Categories

(Other Applications :: ChatZilla, enhancement)

enhancement
Not set
normal

Tracking

(Not tracked)

People

(Reporter: bugzilla-mozilla-20000923, Assigned: rginda)

References

(Blocks 1 open bug)

Details

I had a bit of an interesting idea the other day, regarding various bugs we have. Why not have a Data Manager that helps coordinate fetching data asyncronously?

For example, bug 273505 would like the away message of a user when the mouse of hovered over them in the userlist. This data can be fetched via a /whois command, but that need not be exposed. With the Data Manager, the code could simply do this:
  userObj.getData("awaymsg", callbackFn);

Then, the Data Manager (which would be used to make sure nothing silly happens) would check for cached data (maybe), and then make userObj issue whatever is necessary for "awaymsg" (the objects would define what data properties they have, and only they would know how to fetch it). Then, the object would capture the reply, make sure not to display it (the DM would be able to tell the object that someone requested the data, if the object wasn't sure), and finally pass it to the DM for the callback (and maybe caching).

It sounds more complicated than it is; really, each object would just need to be able to identify data that was requested, and pass over to the DM. This would also be potentially great for commands that show async data (like /whois), because the callback could make sure to always use the correct view for display. :-)

P.S. A different name for this manager wouldn't hurt.
Blocks: 319199
latentReplyManager? Except that sounds way too eloquent for a variable name...
QA Contact: samuel → chatzilla
You need to log in before you can comment on or make changes to this bug.