Class: SequenceServer::InvalidSequenceIdError
- Inherits:
-
ValidationError
- Object
- SequenceServer::InvalidSequenceIdError
- Defined in:
- lib/sequenceserver/api_errors.rb
Overview
InvalidSequenceIdError is raised when the FASTA sequence ID provided by the frontend appears to be invalid. It is important to validate the sequence ID format for security reasons.
Instance Attribute Summary collapse
-
#more_info ⇒ Object
readonly
Returns the value of attribute more_info.
Instance Method Summary collapse
- #http_status ⇒ Object
-
#initialize(more_info) ⇒ InvalidSequenceIdError
constructor
A new instance of InvalidSequenceIdError.
- #message ⇒ Object
- #title ⇒ Object
Constructor Details
#initialize(more_info) ⇒ InvalidSequenceIdError
Returns a new instance of InvalidSequenceIdError.
36 37 38 39 |
# File 'lib/sequenceserver/api_errors.rb', line 36 def initialize(more_info) super @more_info = more_info end |
Instance Attribute Details
#more_info ⇒ Object (readonly)
Returns the value of attribute more_info.
34 35 36 |
# File 'lib/sequenceserver/api_errors.rb', line 34 def more_info @more_info end |
Instance Method Details
#http_status ⇒ Object
41 42 43 |
# File 'lib/sequenceserver/api_errors.rb', line 41 def http_status 422 end |
#message ⇒ Object
49 50 51 52 |
# File 'lib/sequenceserver/api_errors.rb', line 49 def "The action you're trying to perform is not possible because \ one of the FASTA ids seems to be invalid." end |
#title ⇒ Object
45 46 47 |
# File 'lib/sequenceserver/api_errors.rb', line 45 def title 'Sequence ID invalid' end |