def filter(self, *filter, **kw):  # @ReservedAssignment
        """
        Filter results for specific element type.
            
        keyword arguments can be used to specify a match against the
        elements attribute directly. It's important to note that if the
        search filter contains a / or -, the SMC will only search the
        name and comment fields. Otherwise other key fields of an element
        are searched. In addition, SMC searches are a 'contains' search
        meaning you may return more results than wanted. Use a key word
        argument to specify the elements attribute and value expected.
        ::
            
            >>> list(Router.objects.filter('10.10.10.1'))
            [Router(name=Router-110.10.10.10), Router(name=Router-10.10.10.10), Router(name=Router-10.10.10.1)]
            >>> list(Router.objects.filter(address='10.10.10.1'))
            [Router(name=Router-10.10.10.1)]
    
        :param str filter: any parameter to attempt to match on.
            For example, if this is a service, you could match on service name
            'http' or ports of interest, '80'.
        :param bool exact_match: Can be passed as a keyword arg. Specifies whether
            the match needs to be exact or not (default: False)
        :param bool case_sensitive: Can be passed as a keyword arg. Specifies
            whether the match is case sensitive or not. (default: True) 
        :param kw: keyword args can specify an attribute=value to use as an
            exact match against the elements attribute.
        :return: :class:`.ElementCollection`
        """
        iexact = None
        if filter:
            _filter = filter[0]
            
        exact_match = kw.pop('exact_match', False)
        case_sensitive = kw.pop('case_sensitive', True)
        
        if kw:
            _, value = next(iter(kw.items()))
            _filter = value
            iexact = kw
        
        # Only strip metachars from network and address range
        if not exact_match and self._params.get('filter_context', {})\
            in ('network', 'address_range', 'network_elements'):
                _filter = _strip_metachars(_filter)
            
        return self._clone(
            filter=_filter,
            iexact=iexact,
            exact_match=exact_match,
            case_sensitive=case_sensitive)