Why public InputStream getResourceAsStream(String name) is in Class class? It just give inputstream of file which is in jar file and there is no relation with Class class. so it can be static method and it can be in any class.
Why public InputStream getResourceAsStream(String name) is in Class class? It just give inputstream of
Share
There is a relationship to the class:
getResourceAsStream("baz.txt")on the class forfoo.bar.SomeClassit will look for/foo/bar/baz.txt