def overwrites_for(self, obj):
if isinstance(obj, User):<EOL><INDENT>predicate = lambda p: p.type == '<STR_LIT>'<EOL><DEDENT>elif isinstance(obj, Role):<EOL><INDENT>predicate = lambda p: p.type == '<STR_LIT>'<EOL><DEDENT>else:<EOL><INDENT>predicate = lambda p: True<EOL><DEDENT>for overwrite in filter(predicate, self._overwrites):<EOL><INDENT>if overwrite.id == obj.id:<EOL><INDENT>allow = Permissions(overwrite.allow)<EOL>deny = Permissions(overwrite.deny)<EOL>return PermissionOverwrite.from_pair(allow, deny)<EOL><DEDENT><DEDENT>return PermissionOverwrite()<EOL>
Returns the channel-specific overwrites for a member or a role.

        Parameters
        -----------
        obj
            The :class:`Role` or :class:`abc.User` denoting
            whose overwrite to get.

        Returns
        ---------
        :class:`PermissionOverwrite`
            The permission overwrites for this object.