0 purchases
smart reference
Features #
参照カウンタ付きオブジェクトを保持する.
Usage #
var disposed = false;
final ref = SmartReference.wrap(
reference: 100,
dispose: (value) {
disposed = true;
},
);
ref.addRef(); // ref == 2;
ref.release(); // ref == 1;
ref.release(); // ref == 0, call dispose();
copied to clipboard
For personal and professional use. You cannot resell or redistribute these repositories in their original state.
There are no reviews.