Sha256: 64bd19592bb825ede2177be377e3b51c013d2ed76d7312ef8cb10507779e7c3a

Contents?: true

Size: 1.26 KB

Versions: 14

Compression:

Stored size: 1.26 KB

Contents

NTAIL_NAME = 'ntail'
NTAIL_VERSION = '0.0.1'

# module methods to be used as functions...
module NginxTail
  module Inflections
    def self.component_to_module_name(component)
      # this mimicks the ActiveSupport::Inflector.camelize() method in Rails...
      component.to_s.gsub(/\/(.?)/) { "::#{$1.upcase}" }.gsub(/(?:^|_)(.)/) { $1.upcase }
    end
    def self.component_to_ntail_module(component)
      # this mimicks the ActiveSupport::Inflector.constantize() method in Rails...
      NginxTail.const_get(self.component_to_module_name(component)) rescue nil
    end
  end
end

# so-called components...
require 'ntail/remote_addr'
require 'ntail/remote_user'
require 'ntail/time_local'
require 'ntail/request'
require 'ntail/status'
require 'ntail/body_bytes_sent'
require 'ntail/http_referer'
require 'ntail/http_user_agent'
require 'ntail/proxy_addresses'

# so-called sub-components...
require 'ntail/http_method'
require 'ntail/uri'
require 'ntail/http_version'

# additional utility functions...
require 'ntail/known_ip_addresses'
require 'ntail/local_ip_addresses'

# the formatting classes...
require 'ntail/node.rb'
require 'ntail/formatting.rb'

# the core classes...
require 'ntail/log_line.rb'
require 'ntail/options.rb'
require 'ntail/application.rb'

# That's all, Folks!

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
ntail-1.3.2 lib/ntail.rb
ntail-1.3.1 lib/ntail.rb
ntail-1.3.0 lib/ntail.rb
ntail-1.2.0 lib/ntail.rb
ntail-1.1.4 lib/ntail.rb
ntail-1.1.3 lib/ntail.rb
ntail-1.1.2 lib/ntail.rb
ntail-1.1.1 lib/ntail.rb
ntail-1.1.0 lib/ntail.rb
ntail-1.0.2 lib/ntail.rb
ntail-1.0.0 lib/ntail.rb
ntail-0.2.0 lib/ntail.rb
ntail-0.1.0 lib/ntail.rb
ntail-0.0.12 lib/ntail.rb