Example #1
0
File: type.py Project: Bandeira/sps
def get_scanner (type, prop_set):
    """ Returns a scanner instance appropriate to 'type' and 'property_set'.
    """
    if registered (type):
        scanner_type = __types [type]['scanner']
        if scanner_type:
            return scanner.get (scanner_type, prop_set.raw ())
            pass
            
    return None
Example #2
0
def get_scanner(type, prop_set):
    """ Returns a scanner instance appropriate to 'type' and 'property_set'.
    """
    if registered(type):
        scanner_type = __types[type]['scanner']
        if scanner_type:
            return scanner.get(scanner_type, prop_set.raw())
            pass

    return None
Example #3
0
def get_scanner (type, prop_set):
    """ Returns a scanner instance appropriate to 'type' and 'property_set'.
    """
    if __debug__:
        from .property_set import PropertySet
        assert isinstance(type, basestring)
        assert isinstance(prop_set, PropertySet)
    if registered (type):
        scanner_type = __types [type]['scanner']
        if scanner_type:
            return scanner.get (scanner_type, prop_set.raw ())
            pass

    return None
Example #4
0
def get_scanner (type, prop_set):
    """ Returns a scanner instance appropriate to 'type' and 'property_set'.
    """
    if __debug__:
        from .property_set import PropertySet
        assert isinstance(type, basestring)
        assert isinstance(prop_set, PropertySet)
    if registered (type):
        scanner_type = __types [type]['scanner']
        if scanner_type:
            return scanner.get (scanner_type, prop_set.raw ())
            pass

    return None