コード例 #1
0
            /// <summary>
            /// Retrieves the numeric simple log level identifier
            /// corresponding to the given value.
            /// </summary>
            /// <param name="value">
            /// For which to retrieve the numeric simple log level identifier
            /// </param>
            /// <returns>
            /// The corresponding numeric simple log level identifier.
            /// </returns>
            internal static int ToSimpleLogLevel(DatabaseAppLogLevel value)
            {
                int logLevel;

                switch (value)
                {
                case DatabaseAppLogLevel.Error:
                {
                    logLevel = SL.LOG_ERROR;
                    break;
                }

                case DatabaseAppLogLevel.None:
                {
                    logLevel = SL.LOG_NONE;
                    break;
                }

                case DatabaseAppLogLevel.Normal:
                default:
                {
                    logLevel = SL.LOG_NORMAL;

                    break;
                }
                }

                //setProperty(HDP.hsqldb_applog, logLevel);

                return(logLevel);
            }
コード例 #2
0
        internal void SetDatabaseAppLogLevel(object value)
        {
            if (value == null) {
                m_databaseAppLogLevel = DefaultValueOf.DatabaseAppLogLevel;
            } else if (value is DatabaseAppLogLevel) {
                m_databaseAppLogLevel = (DatabaseAppLogLevel) value;
            } else {
                m_databaseAppLogLevel = Util.ConvertToDatabaseAppLogLevel (
                    value);
            }

            if (m_builder != null) {
                m_builder.SetBaseValue (
                    Key.DatabaseAppLogLevel, m_databaseAppLogLevel);
            }
        }
            /// <summary>
            /// Retrieves the numeric simple log level identifier
            /// corresponding to the given value.
            /// </summary>
            /// <param name="value">
            /// For which to retrieve the numeric simple log level identifier
            /// </param>
            /// <returns>
            /// The corresponding numeric simple log level identifier.
            /// </returns>
            internal static int ToSimpleLogLevel(DatabaseAppLogLevel value)
            {
                int logLevel;

                switch (value)
                {
                    case DatabaseAppLogLevel.Error:
                        {
                            logLevel = SL.LOG_ERROR;
                            break;
                        }
                    case DatabaseAppLogLevel.None:
                        {
                            logLevel = SL.LOG_NONE;
                            break;
                        }
                    case DatabaseAppLogLevel.Normal:
                    default:
                        {
                            logLevel = SL.LOG_NORMAL;

                            break;
                        }
                }

                //setProperty(HDP.hsqldb_applog, logLevel);

                return logLevel;
            }