DataOutputStream os = null;
try {
final long timestamp = System.currentTimeMillis();
IRI documentIRI = ont.getOWLOntologyManager().getOntologyDocumentIRI(ont);
final ImportedOntologyMetadata value = new ImportedOntologyMetadata(ont.getOntologyID(), documentIRI, timestamp);
BinaryOWLMetadata metadata = toBinaryOWLMetadata(value);
BinaryOWLOntologyDocumentSerializer serializer = new BinaryOWLOntologyDocumentSerializer();
final File file = getFreshImportCacheFile();