-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Description
This issue was originally filed by [email protected]
Following the Total example code at https://code.google.com/p/dart/source/browse/branches/bleeding_edge/dart/client/samples/total/src/Cell.dart you need to code a lot of setters and getters, which is a pain and bad practice:
class Cell {
CellContent _content;
Set<CellLocation> _dependents;
bool _isStyleDirty;
Style _style;
// the following code should make you cry:
CellContent get content() {
return _content;
}
Set<CellLocation> get dependents() {
return _dependents;
}
Style get style() {
return _style;
}
Have a look at the keywords 'get' and 'set' in C#. For instance getters could be created like this:
CellContent _content { get; };
Set<CellLocation> _dependents { get; };
bool _isStyleDirty { get; };
Style _style { get; }