Class: Sidetree::CAS::FetchResult
- Inherits:
-
Object
- Object
- Sidetree::CAS::FetchResult
- Defined in:
- lib/sidetree/cas/fetch_result.rb
Constant Summary collapse
- CODE_CAS_NOT_REACHABLE =
"cas_not_reachable"
- CODE_INVALID_HASH =
"content_hash_invalid"
- CODE_MAX_SIZE_EXCEEDED =
"content_exceeds_maximum_allowed_size"
- CODE_NOT_FILE =
"content_not_a_file"
- CODE_NOT_FOUND =
"content_not_found"
- CODE_SUCCESS =
"success"
Instance Attribute Summary collapse
-
#code ⇒ Object
readonly
Returns the value of attribute code.
-
#content ⇒ Object
readonly
Returns the value of attribute content.
Instance Method Summary collapse
-
#initialize(code, content = nil) ⇒ FetchResult
constructor
A new instance of FetchResult.
Constructor Details
#initialize(code, content = nil) ⇒ FetchResult
Returns a new instance of FetchResult.
14 15 16 17 |
# File 'lib/sidetree/cas/fetch_result.rb', line 14 def initialize(code, content = nil) @code = code @content = content end |
Instance Attribute Details
#code ⇒ Object (readonly)
Returns the value of attribute code.
11 12 13 |
# File 'lib/sidetree/cas/fetch_result.rb', line 11 def code @code end |
#content ⇒ Object (readonly)
Returns the value of attribute content.
12 13 14 |
# File 'lib/sidetree/cas/fetch_result.rb', line 12 def content @content end |