AppleOpenSource/WebKit2-7609.3.5.1.3/WebProcess/InjectedBundle/API/glib/WebKitConsoleMessage.cpp
/**
 * webkit_console_message_get_level:
 * @console_message: a #WebKitConsoleMessage
 *
 * Gets the log level of a #WebKitConsoleMessage
 *
 * Returns: a #WebKitConsoleMessageLevel indicating the log level of @console_message
 *
 * Since: 2.12
 */


Gets the log level of a #WebKitConsoleMessage

a #WebKitConsoleMessageLevel indicating the log level of @console_message


Gets the log level of a #WebKitConsoleMessage a #WebKitConsoleMessageLevel indicating the log level of @console_message
WebKitConsoleMessageLevel webkit_console_message_get_level(WebKitConsoleMessage* consoleMessage)
{
    g_return_val_if_fail(consoleMessage, WEBKIT_CONSOLE_MESSAGE_LEVEL_LOG);
    switch (consoleMessage->level) {
    case JSC::MessageLevel::Log:
        return WEBKIT_CONSOLE_MESSAGE_LEVEL_LOG;
    case JSC::MessageLevel::Warning:
        return WEBKIT_CONSOLE_MESSAGE_LEVEL_WARNING;
    case JSC::MessageLevel::Error:
        return WEBKIT_CONSOLE_MESSAGE_LEVEL_ERROR;
    case JSC::MessageLevel::Debug:
        return WEBKIT_CONSOLE_MESSAGE_LEVEL_DEBUG;
    case JSC::MessageLevel::Info:
        return WEBKIT_CONSOLE_MESSAGE_LEVEL_INFO;
    }
    ASSERT_NOT_REACHED();
    return WEBKIT_CONSOLE_MESSAGE_LEVEL_LOG;
}
WebKitConsoleMessageLevel webkit_console_message_get_level ( WebKitConsoleMessage * consoleMessage ) { g_return_val_if_fail ( consoleMessage , WEBKIT_CONSOLE_MESSAGE_LEVEL_LOG ) ; switch ( consoleMessage -> level ) { case JSC :: MessageLevel :: Log : return WEBKIT_CONSOLE_MESSAGE_LEVEL_LOG ; case JSC :: MessageLevel :: Warning : return WEBKIT_CONSOLE_MESSAGE_LEVEL_WARNING ; case JSC :: MessageLevel :: Error : return WEBKIT_CONSOLE_MESSAGE_LEVEL_ERROR ; case JSC :: MessageLevel :: Debug : return WEBKIT_CONSOLE_MESSAGE_LEVEL_DEBUG ; case JSC :: MessageLevel :: Info : return WEBKIT_CONSOLE_MESSAGE_LEVEL_INFO ; } ASSERT_NOT_REACHED ( ) ; return WEBKIT_CONSOLE_MESSAGE_LEVEL_LOG ; }
webkit_console_message_get_level:
 @console_message: a #WebKitConsoleMessage
webkit_console_message_get_level : @console_message : a #WebKitConsoleMessage