Copyright © 2015-2016 Takeru Ohta <phjgt308@gmail.com>
Behaviours: logi_sink_file_rotator.
A logi_sink_file_rotator implementation which rotates files by day
> Rotator = logi_sink_file_rotator_daily:new().
> Sink = logi_sink_file:new(foo, "/tmp/{YYYY}-{MM}-{DD}-sample.log", [{rotator, Rotator}]).
> {ok, _} = logi_channel:install_sink(Sink, debug).
> logi:info("hello world").
> file:read_file("/tmp/2015-11-04-sample.log").
{ok,<<"2015-11-04 00:47:39.105 [info] nonode@nohost <0.114.0> erl_eval:do_apply:673 [] hello world\n">>}
new/0 | Equivalent to new(logi_sink_file_rotator_noop:new()). |
new/1 | Creates a new rotator instance. |
new() -> logi_sink_file_rotator:rotator()
Equivalent to new(logi_sink_file_rotator_noop:new()).
new(BaseRotator::logi_sink_file_rotator:rotator()) -> logi_sink_file_rotator:rotator()
Creates a new rotator instance
Generated by EDoc, Sep 27 2018, 23:13:24.