Sha256: 65d179429f8c879e90815c53a384c83eede0ff227a288ceda1764a563b9ab668

Contents?: true

Size: 535 Bytes

Versions: 1

Compression:

Stored size: 535 Bytes

Contents

require 'dry-types'
module HostStatus
  module Types
    include ::Dry::Types.module

    Optional = String.optional.default(nil)
    Url = String.optional.default(nil).constrained format: URI::regexp(%w(http https))
    Percent = Coercible::Float.optional.constrained gteq: 0.0, lteq: 100.0
    Megabyte = Coercible::Float.optional
    RatePerMinute = Coercible::Float.optional.default(nil).constrained gteq: 0.0
    IsUp = Bool.optional.default(nil)
    Count = Coercible::Integer.optional.default(nil).constrained gteq: 0
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
host_status-0.1.0 lib/host_status/types.rb