len = strlen(profile) + 1;
if (!strncmp(PROFILE_MOBILE_STRING, profile, len))
set = PROFILE_MOBILE;
+//LCOV_EXCL_START
else if (!strncmp(PROFILE_WEARABLE_STRING, profile, len))
set = PROFILE_WEARABLE;
else
set = PROFILE_COMMON;
+//LCOV_EXCL_STOP
free(profile);
return set;
if (prof == PROFILE_MOBILE)
profile_name = PROFILE_MOBILE_STRING;
+//LCOV_EXCL_START
else if (prof == PROFILE_WEARABLE)
profile_name = PROFILE_WEARABLE_STRING;
else
profile_name = PROFILE_COMMON_STRING;
+//LCOV_EXCL_STOP
return profile_name;
}
if (prof == PROFILE_MOBILE)
return ARR_SIZE(mobile_str_pattern);
+//LCOV_EXCL_START
else if (prof == PROFILE_WEARABLE)
return ARR_SIZE(wearable_str_pattern);
else
return ARR_SIZE(common_str_pattern);
+//LCOV_EXCL_STOP
}
static const char *profile_str_pattern(int pattern)
if (pattern == mobile_str_pattern[i].id)
return mobile_str_pattern[i].string;
}
+//LCOV_EXCL_START
} else if (prof == PROFILE_WEARABLE) {
for (i = 0; i < profile_get_num_of_pattern(); i++) {
if (pattern == wearable_str_pattern[i].id)
return common_str_pattern[i].string;
}
}
+//LCOV_EXCL_STOP
return "";
}
if (!strncmp(pattern, mobile_str_pattern[i].string, len))
return mobile_str_pattern[i].id;
}
+//LCOV_EXCL_START
} else if (prof == PROFILE_WEARABLE) {
for (i = 0; i < profile_get_num_of_pattern(); i++) {
if (!strncmp(pattern, wearable_str_pattern[i].string, len))
return common_str_pattern[i].id;
}
}
+//LCOV_EXCL_STOP
return -1;
}
if (prof == PROFILE_MOBILE)
return mobile_is_notification_type(pattern);
+//LCOV_EXCL_START
else if (prof == PROFILE_WEARABLE)
return wearable_is_notification_type(pattern);
else
return false;
+//LCOV_EXCL_STOP
}
static int mobile_get_priority(int pattern)
return false;
}
+//LCOV_EXCL_START
static bool wearable_get_always_alert_case(int type, int pattern)
{
if (CHECK_SOUND(type)) {
}
return false;
}
+//LCOV_EXCL_STOP
+//LCOV_EXCL_START
static bool common_get_always_alert_case(int type, int pattern)
{
switch (pattern) {
}
return false;
}
+//LCOV_EXCL_STOP
static bool profile_get_always_alert_case(int type, int pattern)
{
if (prof == PROFILE_MOBILE)
return mobile_get_always_alert_case(type, pattern);
+//LCOV_EXCL_START
else if (prof == PROFILE_WEARABLE)
return wearable_get_always_alert_case(type, pattern);
else
return common_get_always_alert_case(type, pattern);
+//LCOV_EXCL_STOP
}
static bool mobile_get_always_off_case(int type, int pattern)
return false;
}
+//LCOV_EXCL_START
static bool wearable_is_system_type(int pattern)
{
switch (pattern) {
}
return false;
}
+//LCOV_EXCL_STOP
+//LCOV_EXCL_START
static bool common_get_always_off_case(int type, int pattern)
{
switch (pattern) {
}
return false;
}
+//LCOV_EXCL_STOP
static bool profile_get_always_off_case(int type, int pattern)
{
if (prof == PROFILE_MOBILE)
return mobile_get_always_off_case(type, pattern);
+//LCOV_EXCL_START
else if (prof == PROFILE_WEARABLE)
return wearable_get_always_off_case(type, pattern);
else
return common_get_always_off_case(type, pattern);
+//LCOV_EXCL_STOP
}
static int mobile_get_strength_type(int type, int pattern)
return -EINVAL;
}
+//LCOV_EXCL_START
static int wearable_get_strength_type(int type, int pattern)
{
if (CHECK_SOUND(type)) {
}
return -EINVAL;
}
+//LCOV_EXCL_STOP
+//LCOV_EXCL_START
static int common_get_strength_type(int type, int pattern)
{
if (CHECK_SOUND(type)) {
return -EINVAL;
}
+//LCOV_EXCL_STOP
static int profile_get_strength_type(int type, int pattern)
{
if (prof == PROFILE_MOBILE)
return mobile_get_strength_type(type, pattern);
+//LCOV_EXCL_START
else if (prof == PROFILE_WEARABLE)
return wearable_get_strength_type(type, pattern);
else
return common_get_strength_type(type, pattern);
+//LCOV_EXCL_STOP
}
static const struct profile_ops feedback_profile_ops = {