Module: Urbanairship::Loggable
- Included in:
- AbTests::AbTest, AbTests::Experiment, AbTests::Variant, Automations::Automation, Automations::Pipeline, Client, Common::AirshipFailure, Common::PageIterator, CustomEvents::CustomEvent, Devices::APID, Devices::Attribute, Devices::ChannelInfo, Devices::ChannelTags, Devices::ChannelUninstall, Devices::CreateAndSend, Devices::DeviceToken, Devices::DeviceTokenList, Devices::Email, Devices::EmailNotification, Devices::MmsNotification, Devices::NamedUser, Devices::NamedUserUninstaller, Devices::OpenChannel, Devices::OpenChannelUninstall, Devices::Segment, Devices::Sms, Devices::SmsNotification, Devices::StaticList, Devices::TagList, Push::Push, Push::ScheduledPush, Reports::DevicesReport, Reports::IndividualResponseStats
- Defined in:
- lib/urbanairship/loggable.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.create_logger ⇒ Object
13 14 15 16 17 18 19 20 |
# File 'lib/urbanairship/loggable.rb', line 13 def self.create_logger log_uri = [Urbanairship.configuration.log_path, 'urbanairship.log'].compact logger = Logger.new(File.join(*log_uri)) logger.datetime_format = '%Y-%m-%d %H:%M:%S' logger.progname = 'Urbanairship' logger.level = Urbanairship.configuration.log_level logger end |
.logger ⇒ Object
9 10 11 |
# File 'lib/urbanairship/loggable.rb', line 9 def self.logger @logger ||= Urbanairship.configuration.custom_logger || Loggable.create_logger end |