static Pointer<Void> getNativePtr(Graph? obj) { if (obj == null) return Pointer<Void>.fromAddress(0); return (obj as Graph$Impl).ptr; }