Esempio n. 1
0
func (ot *ObjectTemplate) NewObject() *Value {
	ot.Lock()
	defer ot.Unlock()

	if ot.engine == nil {
		return nil
	}

	return newValue(C.V8_ObjectTemplate_NewObject(ot.self))
}
Esempio n. 2
0
func (e *Engine) MakeObject(ot *ObjectTemplate) *Value {
	ot.Lock()
	defer ot.Unlock()

	if ot.engine == nil {
		return nil
	}

	return newValue(e, C.V8_ObjectTemplate_NewObject(e.self, ot.self))
}