//GetAsDecimal Function will return the value as int64 for the specified key.If no value is present for the
//corresponding key then the default value is returned.In case the key is present and it is not decimal error is thrown.
GetAsDecimal Function will return the value as int64 for the specified key.If no value is present for the
corresponding key then the default value is returned.In case the key is present and it is not decimal error is thrown.
// GetAsDecimal Function will return the value as int64 for the specified key . If no value is present for the // corresponding key then the default value is returned . In case the key is present and it is not decimal error is thrown .
func (p *Properties) GetAsDecimal(k string, defaultVal float64) (float64, error) {
	p.RLock()
	defer p.RUnlock()
	if value, ok := p.resolvedProps[k]; ok {
		return strconv.ParseFloat(value, 64)
	}
	return defaultVal, nil
}
func ( p * Properties ) GetAsDecimal ( k string , defaultVal float64 ) ( float64 , error ) { p . RLock ( ) defer p . RUnlock ( ) if value , ok := p . resolvedProps [ k ] ; ok { return strconv . ParseFloat ( value , 64 ) } return defaultVal , nil }
GetAsDecimal Function will return the value as int64 for the specified key.If no value is present for the
corresponding key then the default value is returned.In case the key is present and it is not decimal error is thrown.
GetAsDecimal Function will return the value as int64 for the specified key . If no value is present for the corresponding key then the default value is returned . In case the key is present and it is not decimal error is thrown .