platform/test/shared.dart
2016-12-13 11:34:22 -05:00

21 lines
461 B
Dart

import "package:angel_framework/src/defs.dart";
class Postcard extends MemoryModel {
String location;
String message;
Postcard({String this.location, String this.message});
@override
bool operator ==(other) {
if (!(other is Postcard)) return false;
return id == other.id &&
location == other.location &&
message == other.message;
}
Map toJson() {
return {'id': id, 'location': location, 'message': message};
}
}