Joining a PVC pipe with a chrome plated steel one. Is this possible? If so, how, please?

I'm referring to joining two pipes together, that fit right into each other, so that they're sealed in some way without using some sort of threads.

If using threads of some sort is the recommendation, then, that's okay.

Just looking to see if it's possible, and maybe legal, according to plumbing code, to do such a thing.