Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F78612335
Group.dart
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Wed, Aug 21, 23:24
Size
1 KB
Mime Type
text/x-c++
Expires
Fri, Aug 23, 23:24 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
20073027
Attached To
R10646 Orchestration
Group.dart
View Options
import 'package:firebase_database/firebase_database.dart';
import 'package:flutter/rendering.dart';
Group group = new Group("1", "", "", "");
class Group {
String id = "1";
// String _title;
// String _description;
int inactivity = 0;
String member1name;
String member2name;
String member3name;
int robot1code = 0;
int robot2code = 0;
bool ispaused = false;
int numCurrentActivity = 0;
String robotName = "Cellulo";
Group(this.id, this.member1name, this.member2name, this.member3name);
toJson() {
return {
"member1name": member1name,
"member2name": member2name,
"member3name": member3name,
"robotName": robotName,
"robot1code": robot1code,
"robot2code": robot2code,
"currentActivity": numCurrentActivity,
"isPaused": ispaused,
"inactivity": inactivity,
"id": id,
};
}
Group.fromSnapshot(DataSnapshot snapshot) {
// _id = snapshot.key;
member1name = snapshot.value['member1name'];
member2name = snapshot.value['member2name'];
member3name = snapshot.value['member3name'];
}
}
Event Timeline
Log In to Comment