SharePoint Role Definition / Permission levels
By default SharePoint has list of predefined Role Definitions that gets created during the site creation. If you want to create Additional Role Definitions you can do so by navigating to the Site Permission page and selecting Permission Levels from the Action menu. There will also be cases where we might need to create them programmatically. Here (Please use Save Target as option to down load the file) you can find a small project that creates permission levels programmatically.
I have created this utility, to give more option to the user that is not available/easy in the SharePoint UI. But the one attached here is at very beginning stage; it just does what SP UI does, you can use it to learn how to create Permission levels programmatically. Will update the code once I add more options to it.