Provided is a PIM kinase inhibitor as represented by formula (I), wherein E, J, Q, X, Y, Z, and m are defined in claim 1. The PIM kinase inhibitor of the present invention is used for preparing medicines for treating and preventing cancers, autoimmune diseases, allergic diseases, atherosclerosis and anti-organ transplant rejection reactions.