Exemplo n.º 1
0
func (object_ *Object) GetProperty(key string) *Value {
	//keyPtr := unsafe.Pointer((*reflect.StringHeader)(unsafe.Pointer(&key)).Data)
	keyPtr := StringToPointer(key)
	return NewValue(object_.engine, C.V8_Object_GetProperty(
		object_.self, (*C.char)(keyPtr), C.int(len(key)),
	))
}
Exemplo n.º 2
0
func (o *Object) GetProperty(key string) *Value {
	keyPtr := unsafe.Pointer((*reflect.StringHeader)(unsafe.Pointer(&key)).Data)
	return newValue(C.V8_Object_GetProperty(
		o.self, (*C.char)(keyPtr), C.int(len(key)),
	))
}