Hi Rafey, the answer to your question is the logical address. The router will look at the logical address. The logical address is a 32-bit IP address that is not rooted in the network card. Though it is assigned to it to allow routing between networks.
Hope, the answer will fulfill your requirement. Have a great day!