Both implicitly and, with modest work, explicitly, the  piston  object can discover that it fits into the cylinder hole in the  engine block  object to create a completed piston in a cylinder.
The engine block has a cylinder hole.