// IsCompatible checks if the passed value is compatible with the current MetricType.
IsCompatible checks if the passed value is compatible with the current MetricType.
// IsCompatible checks if the passed value is compatible with the current MetricType .
func (m MetricType) IsCompatible(val interface{}) bool {
	switch v := val.(type) {
	case int:
		return m.isCompatibleInt(v)
	case int32:
		return m == Int32Type
	case int64:
		return m == Int64Type
	case uint:
		return m.isCompatibleUint(v)
	case uint32:
		return m == Uint32Type
	case uint64:
		return m == Uint64Type
	case float32:
		return m == FloatType
	case float64:
		return m.isCompatibleFloat(v)
	case string:
		return m == StringType
	}
	return false
}
func ( m MetricType ) IsCompatible ( val interface { } ) bool { switch v := val . ( type ) { case int : return m . isCompatibleInt ( v ) case int32 : return m == Int32Type case int64 : return m == Int64Type case uint : return m . isCompatibleUint ( v ) case uint32 : return m == Uint32Type case uint64 : return m == Uint64Type case float32 : return m == FloatType case float64 : return m . isCompatibleFloat ( v ) case string : return m == StringType } return false }
IsCompatible checks if the passed value is compatible with the current MetricType.
IsCompatible checks if the passed value is compatible with the current MetricType .