// NewPCPSingletonMetric creates a new instance of PCPSingletonMetric
// it takes 2 extra optional strings as short and long description parameters,
// which on not being present are set to blank strings.
NewPCPSingletonMetric creates a new instance of PCPSingletonMetric
it takes 2 extra optional strings as short and long description parameters,
which on not being present are set to blank strings.
// NewPCPSingletonMetric creates a new instance of PCPSingletonMetric // it takes 2 extra optional strings as short and long description parameters // which on not being present are set to blank strings .
func NewPCPSingletonMetric(val interface{}, name string, t MetricType, s MetricSemantics, u MetricUnit, desc ...string) (*PCPSingletonMetric, error) {
	d, err := newpcpMetricDesc(name, t, s, u, desc...)
	if err != nil {
		return nil, err
	}
	sm, err := newpcpSingletonMetric(val, d)
	if err != nil {
		return nil, err
	}
	return &PCPSingletonMetric{sm, sync.RWMutex{}}, nil
}
func NewPCPSingletonMetric ( val interface { } , name string , t MetricType , s MetricSemantics , u MetricUnit , desc ... string ) ( * PCPSingletonMetric , error ) { d , err := newpcpMetricDesc ( name , t , s , u , desc ... ) if err != nil { return nil , err } sm , err := newpcpSingletonMetric ( val , d ) if err != nil { return nil , err } return & PCPSingletonMetric { sm , sync . RWMutex { } } , nil }
NewPCPSingletonMetric creates a new instance of PCPSingletonMetric
it takes 2 extra optional strings as short and long description parameters,
which on not being present are set to blank strings.
NewPCPSingletonMetric creates a new instance of PCPSingletonMetric it takes 2 extra optional strings as short and long description parameters which on not being present are set to blank strings .