### Summary

Add type hints to `ansible.utils.display::Display`

### Issue Type

Feature Idea

### Component Name

lib/ansible/utils/display.py
settings['ident'] = ident
        
        try:
            if hasattr(self.crypt_algo, 'hash'):
                result = self.crypt_algo.using(**settings).hash(secret)
            elif hasattr(self.crypt_algo, 'encrypt'):
                result = self.crypt_algo.encrypt(secret, **settings)
            else:
                raise AnsibleError("installed passlib version %s not supported" % passlib.__version__)
        except ValueError as e:
            raise AnsibleError("Could not hash the secret.", orig_exc=e)
        
        
        
        if not result:
            raise AnsibleError("failed to hash with algorithm '%s'" % self.algorithm)
        
        
        
        
        return to_text(result, errors='strict')
def passlib_or_crypt(secret, algorithm, salt=None, salt_size=None, rounds=None, ident=None):
    if PASSLIB_AVAILABLE:
        return PasslibHash(algorithm).hash(secret, salt=salt, salt_size=salt_size, rounds=rounds, ident=ident)
    if HAS_CRYPT:
        return CryptHash(algorithm).hash(secret, salt=salt, salt_size=salt_size, rounds=rounds, ident=ident)
    raise AnsibleError("Unable to encrypt nor hash, either crypt or passlib must be installed.", orig_exc=CRYPT_E)
def do_encrypt(result, encrypt, salt_size=None, salt=None, ident=None):
    return passlib_or_crypt(result, encrypt, salt_size=salt_size, salt=salt, ident=ident)