CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutSign UpSign In
rapid7

Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.

GitHub Repository: rapid7/metasploit-framework
Path: blob/master/lib/rex/logging/sinks/flatfile.rb
Views: 11784
1
# -*- coding: binary -*-
2
module Rex
3
module Logging
4
module Sinks
5
6
###
7
#
8
# This class implements the LogSink interface and backs it against a
9
# file on disk.
10
#
11
###
12
class Flatfile < Rex::Logging::Sinks::Stream
13
14
#
15
# Creates a flatfile log sink instance that will be configured to log to
16
# the supplied file path.
17
#
18
def initialize(file)
19
super(File.new(file, 'a'))
20
end
21
22
end
23
24
end end end
25
26