def METHOD_NAME(dest_inst, dest_type, src_props):
    """Match given properties on target instance or type"""
    for pkv in src_props:
        logger.debug("Applying %s", pkv.name)
        # determine target
        target = dest_type if pkv.istype else dest_inst
        # ensure target is valid if it is type
        if pkv.istype and not target:
            logger.warning("Element type is not accessible.")
            continue
        logger.debug("Target is %s", target)
        # find parameter
        dparam = target.LookupParameter(pkv.name)
        if dparam and pkv.datatype == dparam.StorageType:
            try:
                if dparam.StorageType == DB.StorageType.Integer:
                    dparam.Set(pkv.value or 0)
                elif dparam.StorageType == DB.StorageType.Double:
                    dparam.Set(pkv.value or 0.0)
                elif dparam.StorageType == DB.StorageType.ElementId:
                    dparam.Set(DB.ElementId(pkv.value))
                else:
                    dparam.Set(pkv.value or "")
            except Exception as setex:
                logger.warning(
                    "Error applying value to: %s | %s",
                    pkv.name, setex)
                continue
        else:
            logger.debug("Parameter \"%s\"not found on target.", pkv.name)