From Nokia Developer Wiki
The article has well-illustrated the code for receiving SMS on your device and reading it. The class we have used is CSMSReceiver which is derived from MMsvSessionObserver. the class MSmsRecCallCack is used to check if any new SMS is received and the method HandleSessionEventL() and HandleEntryL() are used which are the main mehtod to handle this operation. The comments given in the article are less but the code given is easy to understand.
The article can be useful to the developers who wants to start creating Messaging Applications.