I just learned the way to get resource from Java and see that we can use getResource() to get a resource by two ways.
getResource()
Class.getResource() ClassLoade