get resource from class in lazy inputStream