##### SUMMARY
postgresql_privs module should support a type parameter option for TYPES to allow Grant/Revoke of usage permissions.

##### ISSUE TYPE
- Feature Idea

##### COMPONENT NAME
postgresql_privs

##### ADDITIONAL INFORMATION
Types is supported in for assigning default privs, but we dont have parity for the ability to modify permissions of existing TYPES objects, GRANT USAGE ON TYPE schema.obj TO role;
"""Connection encoding in Python-compatible form"""
        return psycopg2.extensions.encodings[self.connection.encoding]
    
    
    
    
    def schema_exists(self, schema):
        query = """SELECT count(*)
                   FROM pg_catalog.pg_namespace WHERE nspname = %s"""
        self.cursor.execute(query, (schema,))
        return self.cursor.fetchone()[0] > 0
    def get_all_tables_in_schema(self, schema):
        if not self.schema_exists(schema):
            raise Error('Schema "%s" does not exist.' % schema)
        query = """SELECT relname
                   FROM pg_catalog.pg_class c
                   JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace
                   WHERE nspname = %s AND relkind in ('r', 'v', 'm', 'p')"""
        self.cursor.execute(query, (schema,))
        return [t[0] for t in self.cursor.fetchall()]
    def get_all_sequences_in_schema(self, schema):
        if not self.schema_exists(schema):
            raise Error('Schema "%s" does not exist.' % schema)
        query = """SELECT relname
                   FROM pg_catalog.pg_class c
                   JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace
                   WHERE nspname = %s AND relkind = 'S'"""
        self.cursor.execute(query, (schema,))
        return [t[0] for t in self.cursor.fetchall()]
    def get_all_functions_in_schema(self, schema):