It is pad printing.
Pad printing is a process that utilizes a silicon pad, an image that is burned on a plate (also know as a cliche) and specially formulated solvent based inks.
The process works like this, the silicone pad picks up a very thin ink deposit from the imaged plate and transfers it to the substrate.
Pad printing is the standard method of printing many irregularly shaped objects including golf balls, pens, many plastic items and other ad specialty products.
Pad printers are available in both manual and fully automated machines and can range considerably in price. There are several companies who offer entire pad printing packages to help you get started in the business.