The element with the highest value

Property definitions

nitc $ Metric :: max
	# The element with the highest value
	fun max: ELM is abstract
src/metrics/metrics_base.nit:217,2--218,25

nitc $ IntMetric :: max
	redef fun max do
		assert not values_cache.is_empty
		return values_cache.max.as(not null)
	end
src/metrics/metrics_base.nit:253,2--256,4

nitc $ FloatMetric :: max
	redef fun max do
		assert not values.is_empty
		var max: nullable Float = null
		var elem: nullable ELM = null
		for e, v in values do
			if max == null or v > max then
				max = v
				elem = e
			end
		end
		return elem.as(not null)
	end
src/metrics/metrics_base.nit:312,2--323,4