Nope. It's for customs, not immigration. You're already in the country, they just need to figure out whether they need to search your bags for contraband.
Customs agents are supposed to do that. How else do you think smuggling gets stopped? It's pretty much universal that your belongings can be searched (then there are some countries expand that to searching digital data, but that's a bit of a perversion).