Sha256: a992b7587ae9788455e98376a46f372935b456b42f32e3d7457e48d0336e5698

Contents?: true

Size: 1.23 KB

Versions: 10

Compression:

Stored size: 1.23 KB

Contents

module Mihari
  module Structs
    module Rule
      class SearchFilter < Dry::Struct
      end

      class SearchFilterWithPagination < SearchFilter
        def without_pagination: () -> SearchFilter
      end

      class Rule
        attr_reader data: Hash

        attr_reader yaml: String

        attr_reader errors: Array[untypes]?

        def initialize: (Hash data) -> void

        #
        # @return [Boolean]
        #
        def errors?: () -> (bool)

        #
        # @return [Array[String]]
        #
        def error_messages: () -> (Array[String])

        def validate: () -> void

        def validate!: () -> void

        def []: (untyped key) -> untyped

        #
        # @return [String]
        #
        def id: () -> String

        #
        # @return [String]
        #
        def title: () -> String

        #
        # @return [String]
        #
        def description: () -> String

        #
        # @return [Mihari::Rule]
        #
        def to_model: () -> Mihari::Rule

        def to_analyzer: () -> Mihari::Analyzers::Rule

        def self.from_model: (Mihari::Rule model) -> Mihari::Structs::Rule::Rule

        def self.from_yaml: (String yaml) -> Mihari::Structs::Rule::Rule
      end
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
mihari-4.7.1 sig/lib/mihari/structs/rule.rbs
mihari-4.7.0 sig/lib/mihari/structs/rule.rbs
mihari-4.6.1 sig/lib/mihari/structs/rule.rbs
mihari-4.6.0 sig/lib/mihari/structs/rule.rbs
mihari-4.5.3 sig/lib/mihari/structs/rule.rbs
mihari-4.5.2 sig/lib/mihari/structs/rule.rbs
mihari-4.5.1 sig/lib/mihari/structs/rule.rbs
mihari-4.5.0 sig/lib/mihari/structs/rule.rbs
mihari-4.4.1 sig/lib/mihari/structs/rule.rbs
mihari-4.4.0 sig/lib/mihari/structs/rule.rbs