I believe @Mario_Fuchs was suggesting you search the forums so that you would find the following thread, which discusses the code you found as well as newer code and specific implementation issues:
Also remember you can always use the quick browse links from the community-created wiki to quickly find lighting apps or presence apps, or whatever from the community created section of this forum.