Class: OdataDuty::EdmString
Constant Summary collapse
- OAS_TYPE =
{ 'type' => 'string' }.freeze
Class Method Summary collapse
Methods inherited from EdmBase
Class Method Details
.property_type ⇒ Object
31 32 33 |
# File 'lib/odata_duty/edms.rb', line 31 def self.property_type 'Edm.String' end |
.to_oas2(is_collection:) ⇒ Object
37 38 39 40 41 |
# File 'lib/odata_duty/edms.rb', line 37 def self.to_oas2(is_collection:) return { 'type' => 'array', 'items' => OAS_TYPE } if is_collection OAS_TYPE end |
.to_value(object, _context) ⇒ Object
43 44 45 46 47 |
# File 'lib/odata_duty/edms.rb', line 43 def self.to_value(object, _context) object.to_str rescue StandardError => e raise InvalidValue, e end |