Some of my domain classes contain resources (such as StreamController) that need to be disposed. Consequently, I implement dispose method in such classes where I do my cleanup. There is no formal contract in dart (like IDisposable in C#) that would signify this (yes its trivial to implement something similar, I mean there is no built in facility/established style, afaik). So my dispose method is just any other method. User of the class might very well forget to call it someday.
Incidentally, I found out that same StreamController class (for example) somehow "forces" you to call its close() method, by giving a warning in IDE if the instance is encountered without corresponding close() call: Close instances of "dart.core.Sink". I think this is implemented right into dart plugin for this particular class, and I wonder if there is any chance of giving such a warning to the users of my classes that contain dispose. Closest thing I've found is @mustCallSuper that helps with inheritance, but I'm looking for similar solution to the users of my classes.
Shortly, is there something similar to @mustCallSuper and Sink.close() IDE warning, that can be used to bring users' attention to the dispose-required objects?