Method: DS::List#get!
- Defined in:
- lib/ds/lists/list.rb
#get!(x) ⇒ Object
Return ListElement if it is on list or raises error
71 72 73 74 |
# File 'lib/ds/lists/list.rb', line 71 def get!(x) found = get(x) raise ListError, 'Element not found' unless found end |