BZ1147099: Rule Templates: Unable to define in default package and import class

(cherry picked from commit 2732bceafc096ceacac7d444270fbeb78ab4be19)