BigW Consortium Gitlab

core.rb 1.08 KB
Newer Older
1 2 3
module Gitlab
  module Ci
    module Status
4 5
      # Base abstract class fore core status
      #
6
      class Core
7
        include Gitlab::Routing
8
        include Gitlab::Allowable
9

10 11 12
        attr_reader :subject, :user

        def initialize(subject, user)
13
          @subject = subject
14
          @user = user
15 16 17 18 19 20
        end

        def icon
          raise NotImplementedError
        end

21 22 23 24
        def favicon
          raise NotImplementedError
        end

25 26 27 28
        def label
          raise NotImplementedError
        end

29
        def group
30
          self.class.name.demodulize.underscore
31 32
        end

33
        def has_details?
34
          false
35 36 37 38 39 40
        end

        def details_path
          raise NotImplementedError
        end

41
        def has_action?
42
          false
43 44 45 46 47 48 49 50 51
        end

        def action_icon
          raise NotImplementedError
        end

        def action_path
          raise NotImplementedError
        end
52 53 54 55

        def action_method
          raise NotImplementedError
        end
56 57 58 59

        def action_title
          raise NotImplementedError
        end
60 61 62 63
      end
    end
  end
end