Add ObjectDatabase.find method

This method allows to search for an ObjectId by a prefix of the hex
notation. For example search for 0102ab will find the ObjectId
0102abcdef0011 if present. This method only yields an result if there
is exactly one ObjectId present that has the given prefix.
Make DirectoryObjectDatabase use buffered streams