Exemplo n.º 1
0
func FactoryDefault(ident string, cb FactoryF) {
	v := C.CString(ident)
	r := C.gomsgque_FactoryDefault(v, C.MQ_PTR(&cb))
	C.free(unsafe.Pointer(v))
	iErrorFactoryToGoWithCheck(r)
	lockFactory[&cb] = true
}
Exemplo n.º 2
0
func FactoryDefault(ident string, cb FactoryF) *MqFactoryS {
	v := C.CString(ident)
	r := C.gomsgque_FactoryDefault(v, C.MQ_PTR(&cb))
	C.free(unsafe.Pointer(v))
	incrFactoryRef(&cb)
	if r == nil {
		panic("MqFactoryS exception")
	}
	return (*MqFactoryS)(r)
}