ActionBar is available only in Android 3.0 and later, what is a good way to implement ActionBar-like widget in earlier sdk versions? I am looking to do this programmatically without using the main.xml , if that helps.
As @Tony says you can take a look at ActionBarSherlock, a library that provides all ActionBar functionality plus extras (like new Animations and PagerIndicator) back to Android 2.x.
What it basically does is it has an implementation of ActionBar that will be used if you are running your app in a device with Android 2.x. In case that your app is running on a device with Android 3.0 or newer, it will use default Android ActionBar implementation.
I did a post last week showing how to use ActionBarSerlock in your app. If you want, you can take a look at it: Using an ActionBar in your Android app with ActionBarSherlock
You can use ActionBarSherlock (http://actionbarsherlock.com). This will let you have an Action Bar in earlier versions of Android.
Look at the examples app in your samples folder. There is one called actionbarcompat with actionbarcombatability.