How to refer recordtype in Salesforce Apex
use the standard schema object and sobjectType in Apex library Check the syntax ......
Schema. SObjectType. yourSobject. getRecordTypeInfosByName(). get('yourrecordtype APIname'). getRecordTypeId();
BLog Post
How to refer to recordtype in salesforce Apex
Click on the below link for more details
Detail BlogPost