Class: Jschematic::Attributes::Format::Uri
- Inherits:
-
Object
- Object
- Jschematic::Attributes::Format::Uri
show all
- Includes:
- Element
- Defined in:
- lib/jschematic/attributes/format.rb
Instance Attribute Summary
Attributes included from Element
#id, #parent
Instance Method Summary
collapse
Methods included from Element
#required?, #title, #to_s
Instance Method Details
#accepts?(uri) ⇒ Boolean
21
22
23
24
25
|
# File 'lib/jschematic/attributes/format.rb', line 21
def accepts?(uri)
Addressable::URI.parse(uri)
rescue Addressable::URI::InvalidURIError
false
end
|