Ejemplo n.º 1
0
func NewDictProxy(obj Object) (*Dict, error) {
	ret := C.PyDictProxy_New(c(obj))
	if ret == nil {
		return nil, exception()
	}
	return newDict(ret), nil
}
Ejemplo n.º 2
0
// PyObject* PyDictProxy_New(PyObject *dict)
// Return value: New reference.
// Return a proxy object for a mapping which enforces read-only behavior. This is normally used to create a proxy to prevent modification of the dictionary for non-dynamic class types.
//
// New in version 2.2.
func PyDictProxy_New(self *PyObject) *PyObject {
	return togo(C.PyDictProxy_New(topy(self)))
}
Ejemplo n.º 3
0
Archivo: dict.go Proyecto: MogeiWang/py
func NewDictProxy(obj *Base) *Dict {
	ret := C.PyDictProxy_New(obj.c())
	return newDict(ret)
}