The loadOntologyFromOntologyDocument()
method doesn't do any type of reasoning, it just reads the file and loads the corresponding objects into the memory.
As advised before, it's better to read the file directly from the disk and not loading it via a proxy server like localhost
if possible, as it adds more complexity into the process and potentially degrades the performances (you could compare and report the loading times).