Module: RestFilters
- Defined in:
- lib/yard-rest/rest_filters.rb
Instance Method Summary collapse
Instance Method Details
#index_objects(list) ⇒ Object
3 4 5 6 |
# File 'lib/yard-rest/rest_filters.rb', line 3 def index_objects(list) list = reject_without_resource(list) list end |
#reject_without_resource(list) ⇒ Object
8 9 10 11 12 13 14 15 16 |
# File 'lib/yard-rest/rest_filters.rb', line 8 def reject_without_resource(list) list.delete_if { |object| if [:class].include?(object.type) object.meths.detect{|x| x.has_tag? :resource}.nil? else true end } end |