Jump to content

LabVIEW.Messaging.2.0


mje

Recommended Posts

I'm working on a new re-use library which I hope to have in a semi-complete state within the next month. It will ultimately contain much of what was discussed in another thread, but I figured I would post what I have to date, mostly because all the discussions with people at NIWeek have recently got me pretty excited about the advanced OOP based frameworks that are being worked on. I figured I'd throw mine into the fray for comments as well.

It has what I hope to be the next version of my MessagePump framework, and some supporting classes (Callback, and descendants). For the uninitiated, message pumps go by other names such as message loops, event loops, or message dispatchers in other languages. In more traditional LabVIEW lingo, you could recognize a message pump as a consumer portion of many producer-consumer based architectures.

I'll point out that there are some completely unimplemented classes in the attachment as well, this is literally an export from the current (incomplete) source code I'm working off of.

If you download the current snapshot, you'll find a project file in the root directory, or you can browse right to the examples folder if you'd like.

This code is entirely pre-release and not complete. Please do not redistribute it.

Of note:

The MessagePump is now entirely a by reference class. The public interface handles only DVRs, and does I think a decent job of defining an overridable interface which by necessity must be by value (and is not public).

As before I've gone through and made some fairly verbose examples, I think they do a good job demonstrating the fundamental use cases for the class.

Speaking of examples, I dislike #2...It's too much too soon and I need to find a better demo case for callbacks. For now though, it's what's we got.

If you recall the original MessagePump, you'll notice the pump is now entirely FIFO based (no more posting to the front of the queue), and there are absolutely no built in synchronous posting methods. This was a conscious decision.

Finally, unlike the first version which I had been using for about a year before submitting it to LAVA, this version is entirely new and hasn't really been put through it's paces. So if you see something that doesn't seem right, say something...it probably isn't!

Note the code is 2010 only. I don't think it can be saved for previous versions as it uses some of the newer features.

LabVIEW.Messaging.2.0-PR01.zip

Have fun,

-Michael

  • Like 1
Link to comment
  • 1 year later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.