Hi,
Basically Resource mapping means assigning no or resource blocks to particular UE. Say examble 20MHZ BW there are 100 Rb's. If any UE needed resource then Enb will assign required RB to UE.
How UE will come to Know about assigned Resource ??? Ans is Enb will transmit DCI information , with this UE will come to know whether resource is scheduled for this UE or not.
How UE will come to know DCI ?? To send DCI ENB will use PDCCH , So UE will decode this channel every subframe and check whether DCI for this UE or not.
This process is for both UL/ DL. Incase of DL if UE comes to know resource is scheduled then UE will decode the data in those resource. in UL if UE comes to know resource is scheduled then UE will use those resource to send the data. this is basic of resource mapping.
To ans your question : After sending RACH preamble UE will wait to recieve RAR, RAR should reach UE with in RAR window , it is nothing but no of subframes(SF). So ENB will schedule RAR with in those SF and sents the RAR DCI to notify UE. UE will decode RAR DCI then he will decode RAR content. Same process is for contention resoultion mesasge also.