title: java reflection: get list of classes in a package at compile to use at runtime
body: <p>I have console application that do some reflection operations on list of classes (log field names, annotations, etc.).</p>
  
  <p>Right now I create list of classnames by hand as strings in a file. I would love to be able to add project/package/configure path to build folder/etc. to my console project, build it and somehow use classnames got during compile in runtime.</p>
  
  <p>Simple usecase: compile my app with a package, run on production site to check if every data class has proper database configuration.</p>
  
  <p>Found this solution:
  <a href="https://dzone.com/articles/get-all-classes-within-package" rel="nofollow noreferrer">https://dzone.com/articles/get-all-classes-within-package</a> but it works during runtime and I prefer to get those names during compile time... is it possible? Or am I getting this wrong?</p>