<commit_before># @Author: <NAME>
# @Date:   2016-07-15 16:06:08
# @Last Modified by:   <NAME>
# @Last Modified time: 2016-07-28 16:21:01

module Menu

  class IndexMenu < Base
    include Listenable

    def initialize
      @menu_description = 'Index menu. Select the criteria for the index:'
      super
    end

    private

    def define_menu_items
      add_menu_item('Http request', 1)
      add_menu_item('Http status', 2)
      add_menu_item('Sourceadress', 3)
      add_menu_item('Timestamp', 4)
    end

    def determine_action(input)
      case (input.to_i)
        when 1 then notify_listeners(:change_index, :http_request)<commit_msg>added documentation to index menu<commit_after># @Author: <NAME>
# @Date:   2016-07-15 16:06:08
# @Last Modified by:   <NAME>
# @Last Modified time: 2016-09-18 17:32:42

module Menu

  # menu class that inherits {Menu::Base} to abstract the menu to select a
  # given status
  class IndexMenu < Base
    include Listenable

    # initialization
    def initialize
      @menu_description = 'Index menu. Select the criteria for the index:'
      super
    end

    private

    # implementation to define the items of the menu
    def define_menu_items
      add_menu_item('Http request', 1)
      add_menu_item('Http status', 2)
      add_menu_item('Sourceadress', 3)
      add_menu_item('Timestamp', 4)
    end

    # method to specify the actions to a given input
    # @param [String] input the user input
    def determine_action(input)
      case (input.to_i)
        when 1 then notify_listeners(:change_index, :http_request)
{'fraction_non_alphanumeric': 0.08924050632911393, 'fraction_numerical': 0.04177215189873418, 'mean_word_length': 3.1064935064935066, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1320909', 'n_tokens_mistral': 545, 'n_tokens_neox': 481, 'n_words': 157}