Class: Homebrew::Attestation::Verifier::ValidityPeriod Private
- Defined in:
- attestation/verifier.rb
This class is part of a private API. This class may only be used in the Homebrew/brew repository. Third parties should avoid using this class if possible, as it may be removed or changed without warning.
Instance Attribute Summary collapse
-
#end_time ⇒ Time?
readonly
private
Returns the value of prop
end_time. -
#start_time ⇒ Time
readonly
private
Returns the value of prop
start_time.
Instance Method Summary collapse
- #covers?(time) ⇒ Boolean private
- #initialize(start_time:, end_time: nil) ⇒ void constructor
Constructor Details
Instance Attribute Details
#end_time ⇒ Time? (readonly)
This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.
Returns the value of prop end_time.
|
|
# File '' const :end_time, T.nilable(Time) |
#start_time ⇒ Time (readonly)
This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.
Returns the value of prop start_time.
|
|
# File '' const :start_time, Time |
Instance Method Details
#covers?(time) ⇒ Boolean
This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.
85 86 87 88 |
# File 'attestation/verifier.rb', line 85 def covers?(time) expiry = end_time time >= start_time && (!expiry || time <= expiry) end |