Class: Contracts::Formatters::ClassInspectWrapper
- Inherits:
-
Object
- Object
- Contracts::Formatters::ClassInspectWrapper
show all
- Includes:
- InspectWrapper
- Defined in:
- lib/contracts/formatters.rb
Instance Method Summary
collapse
create, #delim, #initialize, #inspect, inspector_klass, #to_s
Instance Method Details
#custom_to_s? ⇒ Boolean
112
113
114
|
# File 'lib/contracts/formatters.rb', line 112
def custom_to_s?
@value.to_s != @value.name
end
|
#useful_inspect ⇒ Object
116
117
118
|
# File 'lib/contracts/formatters.rb', line 116
def useful_inspect
strip_prefix(empty_to_s? ? @value.name : @value.inspect)
end
|