SlideShare a Scribd company logo
Creating a Facebook Clone - Part XIV
public class Notification implements PropertyBusinessObject {
public final Property<String, Notification> id = new Property<>("id");
public final Property<User, Notification> user =
new Property<>("user", User.class);
public final Property<String, Notification> text =
new Property<>("text");
public final Property<String, Notification> reaction =
new Property<>("reaction");
public final IntProperty<Notification> reactionColor =
new IntProperty<>("reactionColor");
public final LongProperty<Notification> date =
new LongProperty<>("date");
public final BooleanProperty<Notification> wasRead =
new BooleanProperty<>("wasRead");
private final PropertyIndex idx=new PropertyIndex(this,"Notification",
id, user, text, reaction, reactionColor, date, wasRead);
@Override
public PropertyIndex getPropertyIndex() {
return idx;
}
}
FriendsContainer
public class Notification implements PropertyBusinessObject {
public final Property<String, Notification> id = new Property<>("id");
public final Property<User, Notification> user =
new Property<>("user", User.class);
public final Property<String, Notification> text =
new Property<>("text");
public final Property<String, Notification> reaction =
new Property<>("reaction");
public final IntProperty<Notification> reactionColor =
new IntProperty<>("reactionColor");
public final LongProperty<Notification> date =
new LongProperty<>("date");
public final BooleanProperty<Notification> wasRead =
new BooleanProperty<>("wasRead");
private final PropertyIndex idx=new PropertyIndex(this,"Notification",
id, user, text, reaction, reactionColor, date, wasRead);
@Override
public PropertyIndex getPropertyIndex() {
return idx;
}
}
FriendsContainer
public class Notification implements PropertyBusinessObject {
public final Property<String, Notification> id = new Property<>("id");
public final Property<User, Notification> user =
new Property<>("user", User.class);
public final Property<String, Notification> text =
new Property<>("text");
public final Property<String, Notification> reaction =
new Property<>("reaction");
public final IntProperty<Notification> reactionColor =
new IntProperty<>("reactionColor");
public final LongProperty<Notification> date =
new LongProperty<>("date");
public final BooleanProperty<Notification> wasRead =
new BooleanProperty<>("wasRead");
private final PropertyIndex idx=new PropertyIndex(this,"Notification",
id, user, text, reaction, reactionColor, date, wasRead);
@Override
public PropertyIndex getPropertyIndex() {
return idx;
}
}
FriendsContainer
public class Notification implements PropertyBusinessObject {
public final Property<String, Notification> id = new Property<>("id");
public final Property<User, Notification> user =
new Property<>("user", User.class);
public final Property<String, Notification> text =
new Property<>("text");
public final Property<String, Notification> reaction =
new Property<>("reaction");
public final IntProperty<Notification> reactionColor =
new IntProperty<>("reactionColor");
public final LongProperty<Notification> date =
new LongProperty<>("date");
public final BooleanProperty<Notification> wasRead =
new BooleanProperty<>("wasRead");
private final PropertyIndex idx=new PropertyIndex(this,"Notification",
id, user, text, reaction, reactionColor, date, wasRead);
@Override
public PropertyIndex getPropertyIndex() {
return idx;
}
}
FriendsContainer
return null;
}
public static List<Notification> fetchNotifications(
long since, int amount) {
if(since < initTime - UIUtils.DAY) {
return null;
}
List<Notification> response = new ArrayList<>();
response.add(new Notification().id.set("Notify-1").
user.set(dummyUsers[0]).
text.set("liked Your Post").
date.set(initTime - 60000).
reaction.set("" + FontImage.MATERIAL_FAVORITE).
reactionColor.set(0xff0000));
response.add(new Notification().id.set("Notify-2").
user.set(dummyUsers[1]).
text.set("commented on your post").
date.set(initTime - 600000000).
reaction.set("" + FontImage.MATERIAL_CHAT).
reactionColor.set(0xff00));
return response;
}
ServerAPI
return null;
}
public static List<Notification> fetchNotifications(
long since, int amount) {
if(since < initTime - UIUtils.DAY) {
return null;
}
List<Notification> response = new ArrayList<>();
response.add(new Notification().id.set("Notify-1").
user.set(dummyUsers[0]).
text.set("liked Your Post").
date.set(initTime - 60000).
reaction.set("" + FontImage.MATERIAL_FAVORITE).
reactionColor.set(0xff0000));
response.add(new Notification().id.set("Notify-2").
user.set(dummyUsers[1]).
text.set("commented on your post").
date.set(initTime - 600000000).
reaction.set("" + FontImage.MATERIAL_CHAT).
reactionColor.set(0xff00));
return response;
}
ServerAPI
return null;
}
public static List<Notification> fetchNotifications(
long since, int amount) {
if(since < initTime - UIUtils.DAY) {
return null;
}
List<Notification> response = new ArrayList<>();
response.add(new Notification().id.set("Notify-1").
user.set(dummyUsers[0]).
text.set("liked Your Post").
date.set(initTime - 60000).
reaction.set("" + FontImage.MATERIAL_FAVORITE).
reactionColor.set(0xff0000));
response.add(new Notification().id.set("Notify-2").
user.set(dummyUsers[1]).
text.set("commented on your post").
date.set(initTime - 600000000).
reaction.set("" + FontImage.MATERIAL_CHAT).
reactionColor.set(0xff00));
return response;
}
ServerAPI
© Codename One 2017 all rights reserved
public class NotificationsContainer extends InfiniteContainer {
private long lastTime;
@Override
public Component[] fetchComponents(int index, int amount) {
if(index == 0) {
lastTime = System.currentTimeMillis();
}
List<Notification> response = ServerAPI.fetchNotifications(lastTime,
amount);
if(response == null) {
return null;
}
Component[] notifications = new Component[response.size()];
int iter = 0;
for(Notification n : response) {
lastTime = n.date.getLong();
notifications[iter] = createNotificationEntry(n);
iter++;
}
NotificationsContainer
public class NotificationsContainer extends InfiniteContainer {
private long lastTime;
@Override
public Component[] fetchComponents(int index, int amount) {
if(index == 0) {
lastTime = System.currentTimeMillis();
}
List<Notification> response = ServerAPI.fetchNotifications(lastTime,
amount);
if(response == null) {
return null;
}
Component[] notifications = new Component[response.size()];
int iter = 0;
for(Notification n : response) {
lastTime = n.date.getLong();
notifications[iter] = createNotificationEntry(n);
iter++;
}
NotificationsContainer
notifications[iter] = createNotificationEntry(n);
iter++;
}
return notifications;
}
private Container createNotificationEntry(Notification n) {
Image avatar = n.user.get().getAvatar(13);
Label icon = new Label("", "SmallBlueCircle");
icon.getAllStyles().setBorder(RoundBorder.create().
color(n.reactionColor.get()));
FontImage.setMaterialIcon(icon, n.reaction.get().charAt(0), 2);
Container avatarContainer = LayeredLayout.encloseIn(
new Label(avatar, "HalfPaddedContainer"),
FlowLayout.encloseRightBottom(icon));
RichTextView rt = new RichTextView("<b>" + n.user.get().fullName() +
"</b> " + n.text.get());
Label time = new Label(UIUtils.formatTimeAgo(n.date.get()),
"SmallBlueLabel");
Container yContainer = BoxLayout.encloseY(rt, time);
yContainer.setUIID("HalfPaddedContainer");
return BorderLayout.
centerEastWest(yContainer, null, avatarContainer);
}
NotificationsContainer
notifications[iter] = createNotificationEntry(n);
iter++;
}
return notifications;
}
private Container createNotificationEntry(Notification n) {
Image avatar = n.user.get().getAvatar(13);
Label icon = new Label("", "SmallBlueCircle");
icon.getAllStyles().setBorder(RoundBorder.create().
color(n.reactionColor.get()));
FontImage.setMaterialIcon(icon, n.reaction.get().charAt(0), 2);
Container avatarContainer = LayeredLayout.encloseIn(
new Label(avatar, "HalfPaddedContainer"),
FlowLayout.encloseRightBottom(icon));
RichTextView rt = new RichTextView("<b>" + n.user.get().fullName() +
"</b> " + n.text.get());
Label time = new Label(UIUtils.formatTimeAgo(n.date.get()),
"SmallBlueLabel");
Container yContainer = BoxLayout.encloseY(rt, time);
yContainer.setUIID("HalfPaddedContainer");
return BorderLayout.
centerEastWest(yContainer, null, avatarContainer);
}
NotificationsContainer
notifications[iter] = createNotificationEntry(n);
iter++;
}
return notifications;
}
private Container createNotificationEntry(Notification n) {
Image avatar = n.user.get().getAvatar(13);
Label icon = new Label("", "SmallBlueCircle");
icon.getAllStyles().setBorder(RoundBorder.create().
color(n.reactionColor.get()));
FontImage.setMaterialIcon(icon, n.reaction.get().charAt(0), 2);
Container avatarContainer = LayeredLayout.encloseIn(
new Label(avatar, "HalfPaddedContainer"),
FlowLayout.encloseRightBottom(icon));
RichTextView rt = new RichTextView("<b>" + n.user.get().fullName() +
"</b> " + n.text.get());
Label time = new Label(UIUtils.formatTimeAgo(n.date.get()),
"SmallBlueLabel");
Container yContainer = BoxLayout.encloseY(rt, time);
yContainer.setUIID("HalfPaddedContainer");
return BorderLayout.
centerEastWest(yContainer, null, avatarContainer);
}
NotificationsContainer
notifications[iter] = createNotificationEntry(n);
iter++;
}
return notifications;
}
private Container createNotificationEntry(Notification n) {
Image avatar = n.user.get().getAvatar(13);
Label icon = new Label("", "SmallBlueCircle");
icon.getAllStyles().setBorder(RoundBorder.create().
color(n.reactionColor.get()));
FontImage.setMaterialIcon(icon, n.reaction.get().charAt(0), 2);
Container avatarContainer = LayeredLayout.encloseIn(
new Label(avatar, "HalfPaddedContainer"),
FlowLayout.encloseRightBottom(icon));
RichTextView rt = new RichTextView("<b>" + n.user.get().fullName() +
"</b> " + n.text.get());
Label time = new Label(UIUtils.formatTimeAgo(n.date.get()),
"SmallBlueLabel");
Container yContainer = BoxLayout.encloseY(rt, time);
yContainer.setUIID("HalfPaddedContainer");
return BorderLayout.
centerEastWest(yContainer, null, avatarContainer);
}
NotificationsContainer
SmallBlueLabel {
color: blue;
font-size: 2mm;
padding: 1mm;
font-family: "native:MainLight";
}
theme.css

More Related Content

Similar to Creating a Facebook Clone - Part XIV.pdf

That’s My App - Running in Your Background - Draining Your Battery
That’s My App - Running in Your Background - Draining Your BatteryThat’s My App - Running in Your Background - Draining Your Battery
That’s My App - Running in Your Background - Draining Your Battery
Michael Galpin
 
Creating a Facebook Clone - Part XXIII.pdf
Creating a Facebook Clone - Part XXIII.pdfCreating a Facebook Clone - Part XXIII.pdf
Creating a Facebook Clone - Part XXIII.pdf
ShaiAlmog1
 
UI Design From Scratch - Part 5.pdf
UI Design From Scratch - Part 5.pdfUI Design From Scratch - Part 5.pdf
UI Design From Scratch - Part 5.pdf
ShaiAlmog1
 
Creating a Facebook Clone - Part XII.pdf
Creating a Facebook Clone - Part XII.pdfCreating a Facebook Clone - Part XII.pdf
Creating a Facebook Clone - Part XII.pdf
ShaiAlmog1
 
Android studio plugin 作ってみた 〜 create intent method generator 〜
Android studio plugin 作ってみた 〜 create intent method generator 〜Android studio plugin 作ってみた 〜 create intent method generator 〜
Android studio plugin 作ってみた 〜 create intent method generator 〜
外山 椋
 
create-netflix-clone-05-client-model.pdf
create-netflix-clone-05-client-model.pdfcreate-netflix-clone-05-client-model.pdf
create-netflix-clone-05-client-model.pdf
ShaiAlmog1
 
Demystifying Reactive Programming
Demystifying Reactive ProgrammingDemystifying Reactive Programming
Demystifying Reactive Programming
Tom Bulatewicz, PhD
 
Creating a Facebook Clone - Part XX - Transcript.pdf
Creating a Facebook Clone - Part XX - Transcript.pdfCreating a Facebook Clone - Part XX - Transcript.pdf
Creating a Facebook Clone - Part XX - Transcript.pdf
ShaiAlmog1
 
Creating an Uber Clone - Part XXXX.pdf
Creating an Uber Clone - Part XXXX.pdfCreating an Uber Clone - Part XXXX.pdf
Creating an Uber Clone - Part XXXX.pdf
ShaiAlmog1
 
Creating a Facebook Clone - Part XL - Transcript.pdf
Creating a Facebook Clone - Part XL - Transcript.pdfCreating a Facebook Clone - Part XL - Transcript.pdf
Creating a Facebook Clone - Part XL - Transcript.pdf
ShaiAlmog1
 
Creating a Facebook Clone - Part XI.pdf
Creating a Facebook Clone - Part XI.pdfCreating a Facebook Clone - Part XI.pdf
Creating a Facebook Clone - Part XI.pdf
ShaiAlmog1
 
A GWT Application with MVP Pattern Deploying to CloudFoundry using Spring Roo
A GWT Application with MVP Pattern Deploying to CloudFoundry using  Spring Roo A GWT Application with MVP Pattern Deploying to CloudFoundry using  Spring Roo
A GWT Application with MVP Pattern Deploying to CloudFoundry using Spring Roo
Ali Parmaksiz
 
Creating a Whatsapp Clone - Part III.pdf
Creating a Whatsapp Clone - Part III.pdfCreating a Whatsapp Clone - Part III.pdf
Creating a Whatsapp Clone - Part III.pdf
ShaiAlmog1
 
Creating a Facebook Clone - Part XX.pdf
Creating a Facebook Clone - Part XX.pdfCreating a Facebook Clone - Part XX.pdf
Creating a Facebook Clone - Part XX.pdf
ShaiAlmog1
 
Java beginners meetup: Introduction to class and application design
Java beginners meetup: Introduction to class and application designJava beginners meetup: Introduction to class and application design
Java beginners meetup: Introduction to class and application design
Patrick Kostjens
 
Android Event and IntentAndroid Event and Intent
Android Event and IntentAndroid Event and IntentAndroid Event and IntentAndroid Event and Intent
Android Event and IntentAndroid Event and Intent
admin220812
 
Java весна 2013 лекция 2
Java весна 2013 лекция 2Java весна 2013 лекция 2
Java весна 2013 лекция 2Technopark
 
Creating a Facebook Clone - Part XII - Transcript.pdf
Creating a Facebook Clone - Part XII - Transcript.pdfCreating a Facebook Clone - Part XII - Transcript.pdf
Creating a Facebook Clone - Part XII - Transcript.pdf
ShaiAlmog1
 

Similar to Creating a Facebook Clone - Part XIV.pdf (20)

That’s My App - Running in Your Background - Draining Your Battery
That’s My App - Running in Your Background - Draining Your BatteryThat’s My App - Running in Your Background - Draining Your Battery
That’s My App - Running in Your Background - Draining Your Battery
 
Creating a Facebook Clone - Part XXIII.pdf
Creating a Facebook Clone - Part XXIII.pdfCreating a Facebook Clone - Part XXIII.pdf
Creating a Facebook Clone - Part XXIII.pdf
 
UI Design From Scratch - Part 5.pdf
UI Design From Scratch - Part 5.pdfUI Design From Scratch - Part 5.pdf
UI Design From Scratch - Part 5.pdf
 
Creating a Facebook Clone - Part XII.pdf
Creating a Facebook Clone - Part XII.pdfCreating a Facebook Clone - Part XII.pdf
Creating a Facebook Clone - Part XII.pdf
 
Android studio plugin 作ってみた 〜 create intent method generator 〜
Android studio plugin 作ってみた 〜 create intent method generator 〜Android studio plugin 作ってみた 〜 create intent method generator 〜
Android studio plugin 作ってみた 〜 create intent method generator 〜
 
create-netflix-clone-05-client-model.pdf
create-netflix-clone-05-client-model.pdfcreate-netflix-clone-05-client-model.pdf
create-netflix-clone-05-client-model.pdf
 
Demystifying Reactive Programming
Demystifying Reactive ProgrammingDemystifying Reactive Programming
Demystifying Reactive Programming
 
Creating a Facebook Clone - Part XX - Transcript.pdf
Creating a Facebook Clone - Part XX - Transcript.pdfCreating a Facebook Clone - Part XX - Transcript.pdf
Creating a Facebook Clone - Part XX - Transcript.pdf
 
Creating an Uber Clone - Part XXXX.pdf
Creating an Uber Clone - Part XXXX.pdfCreating an Uber Clone - Part XXXX.pdf
Creating an Uber Clone - Part XXXX.pdf
 
Creating a Facebook Clone - Part XL - Transcript.pdf
Creating a Facebook Clone - Part XL - Transcript.pdfCreating a Facebook Clone - Part XL - Transcript.pdf
Creating a Facebook Clone - Part XL - Transcript.pdf
 
Creating a Facebook Clone - Part XI.pdf
Creating a Facebook Clone - Part XI.pdfCreating a Facebook Clone - Part XI.pdf
Creating a Facebook Clone - Part XI.pdf
 
A GWT Application with MVP Pattern Deploying to CloudFoundry using Spring Roo
A GWT Application with MVP Pattern Deploying to CloudFoundry using  Spring Roo A GWT Application with MVP Pattern Deploying to CloudFoundry using  Spring Roo
A GWT Application with MVP Pattern Deploying to CloudFoundry using Spring Roo
 
Creating a Whatsapp Clone - Part III.pdf
Creating a Whatsapp Clone - Part III.pdfCreating a Whatsapp Clone - Part III.pdf
Creating a Whatsapp Clone - Part III.pdf
 
Creating a Facebook Clone - Part XX.pdf
Creating a Facebook Clone - Part XX.pdfCreating a Facebook Clone - Part XX.pdf
Creating a Facebook Clone - Part XX.pdf
 
Java beginners meetup: Introduction to class and application design
Java beginners meetup: Introduction to class and application designJava beginners meetup: Introduction to class and application design
Java beginners meetup: Introduction to class and application design
 
Android Event and IntentAndroid Event and Intent
Android Event and IntentAndroid Event and IntentAndroid Event and IntentAndroid Event and Intent
Android Event and IntentAndroid Event and Intent
 
Java весна 2013 лекция 2
Java весна 2013 лекция 2Java весна 2013 лекция 2
Java весна 2013 лекция 2
 
16 18
16 1816 18
16 18
 
Creating a Facebook Clone - Part XII - Transcript.pdf
Creating a Facebook Clone - Part XII - Transcript.pdfCreating a Facebook Clone - Part XII - Transcript.pdf
Creating a Facebook Clone - Part XII - Transcript.pdf
 
Mattbrenner
MattbrennerMattbrenner
Mattbrenner
 

More from ShaiAlmog1

The Duck Teaches Learn to debug from the masters. Local to production- kill ...
The Duck Teaches  Learn to debug from the masters. Local to production- kill ...The Duck Teaches  Learn to debug from the masters. Local to production- kill ...
The Duck Teaches Learn to debug from the masters. Local to production- kill ...
ShaiAlmog1
 
create-netflix-clone-06-client-ui.pdf
create-netflix-clone-06-client-ui.pdfcreate-netflix-clone-06-client-ui.pdf
create-netflix-clone-06-client-ui.pdf
ShaiAlmog1
 
create-netflix-clone-01-introduction_transcript.pdf
create-netflix-clone-01-introduction_transcript.pdfcreate-netflix-clone-01-introduction_transcript.pdf
create-netflix-clone-01-introduction_transcript.pdf
ShaiAlmog1
 
create-netflix-clone-02-server_transcript.pdf
create-netflix-clone-02-server_transcript.pdfcreate-netflix-clone-02-server_transcript.pdf
create-netflix-clone-02-server_transcript.pdf
ShaiAlmog1
 
create-netflix-clone-04-server-continued_transcript.pdf
create-netflix-clone-04-server-continued_transcript.pdfcreate-netflix-clone-04-server-continued_transcript.pdf
create-netflix-clone-04-server-continued_transcript.pdf
ShaiAlmog1
 
create-netflix-clone-01-introduction.pdf
create-netflix-clone-01-introduction.pdfcreate-netflix-clone-01-introduction.pdf
create-netflix-clone-01-introduction.pdf
ShaiAlmog1
 
create-netflix-clone-06-client-ui_transcript.pdf
create-netflix-clone-06-client-ui_transcript.pdfcreate-netflix-clone-06-client-ui_transcript.pdf
create-netflix-clone-06-client-ui_transcript.pdf
ShaiAlmog1
 
create-netflix-clone-03-server.pdf
create-netflix-clone-03-server.pdfcreate-netflix-clone-03-server.pdf
create-netflix-clone-03-server.pdf
ShaiAlmog1
 
create-netflix-clone-04-server-continued.pdf
create-netflix-clone-04-server-continued.pdfcreate-netflix-clone-04-server-continued.pdf
create-netflix-clone-04-server-continued.pdf
ShaiAlmog1
 
create-netflix-clone-05-client-model_transcript.pdf
create-netflix-clone-05-client-model_transcript.pdfcreate-netflix-clone-05-client-model_transcript.pdf
create-netflix-clone-05-client-model_transcript.pdf
ShaiAlmog1
 
create-netflix-clone-03-server_transcript.pdf
create-netflix-clone-03-server_transcript.pdfcreate-netflix-clone-03-server_transcript.pdf
create-netflix-clone-03-server_transcript.pdf
ShaiAlmog1
 
create-netflix-clone-02-server.pdf
create-netflix-clone-02-server.pdfcreate-netflix-clone-02-server.pdf
create-netflix-clone-02-server.pdf
ShaiAlmog1
 
Creating a Whatsapp Clone - Part II.pdf
Creating a Whatsapp Clone - Part II.pdfCreating a Whatsapp Clone - Part II.pdf
Creating a Whatsapp Clone - Part II.pdf
ShaiAlmog1
 
Creating a Whatsapp Clone - Part IX - Transcript.pdf
Creating a Whatsapp Clone - Part IX - Transcript.pdfCreating a Whatsapp Clone - Part IX - Transcript.pdf
Creating a Whatsapp Clone - Part IX - Transcript.pdf
ShaiAlmog1
 
Creating a Whatsapp Clone - Part II - Transcript.pdf
Creating a Whatsapp Clone - Part II - Transcript.pdfCreating a Whatsapp Clone - Part II - Transcript.pdf
Creating a Whatsapp Clone - Part II - Transcript.pdf
ShaiAlmog1
 
Creating a Whatsapp Clone - Part V - Transcript.pdf
Creating a Whatsapp Clone - Part V - Transcript.pdfCreating a Whatsapp Clone - Part V - Transcript.pdf
Creating a Whatsapp Clone - Part V - Transcript.pdf
ShaiAlmog1
 
Creating a Whatsapp Clone - Part I - Transcript.pdf
Creating a Whatsapp Clone - Part I - Transcript.pdfCreating a Whatsapp Clone - Part I - Transcript.pdf
Creating a Whatsapp Clone - Part I - Transcript.pdf
ShaiAlmog1
 
Creating a Whatsapp Clone - Part IX.pdf
Creating a Whatsapp Clone - Part IX.pdfCreating a Whatsapp Clone - Part IX.pdf
Creating a Whatsapp Clone - Part IX.pdf
ShaiAlmog1
 
Creating a Whatsapp Clone - Part VI.pdf
Creating a Whatsapp Clone - Part VI.pdfCreating a Whatsapp Clone - Part VI.pdf
Creating a Whatsapp Clone - Part VI.pdf
ShaiAlmog1
 
Creating a Whatsapp Clone - Part III - Transcript.pdf
Creating a Whatsapp Clone - Part III - Transcript.pdfCreating a Whatsapp Clone - Part III - Transcript.pdf
Creating a Whatsapp Clone - Part III - Transcript.pdf
ShaiAlmog1
 

More from ShaiAlmog1 (20)

The Duck Teaches Learn to debug from the masters. Local to production- kill ...
The Duck Teaches  Learn to debug from the masters. Local to production- kill ...The Duck Teaches  Learn to debug from the masters. Local to production- kill ...
The Duck Teaches Learn to debug from the masters. Local to production- kill ...
 
create-netflix-clone-06-client-ui.pdf
create-netflix-clone-06-client-ui.pdfcreate-netflix-clone-06-client-ui.pdf
create-netflix-clone-06-client-ui.pdf
 
create-netflix-clone-01-introduction_transcript.pdf
create-netflix-clone-01-introduction_transcript.pdfcreate-netflix-clone-01-introduction_transcript.pdf
create-netflix-clone-01-introduction_transcript.pdf
 
create-netflix-clone-02-server_transcript.pdf
create-netflix-clone-02-server_transcript.pdfcreate-netflix-clone-02-server_transcript.pdf
create-netflix-clone-02-server_transcript.pdf
 
create-netflix-clone-04-server-continued_transcript.pdf
create-netflix-clone-04-server-continued_transcript.pdfcreate-netflix-clone-04-server-continued_transcript.pdf
create-netflix-clone-04-server-continued_transcript.pdf
 
create-netflix-clone-01-introduction.pdf
create-netflix-clone-01-introduction.pdfcreate-netflix-clone-01-introduction.pdf
create-netflix-clone-01-introduction.pdf
 
create-netflix-clone-06-client-ui_transcript.pdf
create-netflix-clone-06-client-ui_transcript.pdfcreate-netflix-clone-06-client-ui_transcript.pdf
create-netflix-clone-06-client-ui_transcript.pdf
 
create-netflix-clone-03-server.pdf
create-netflix-clone-03-server.pdfcreate-netflix-clone-03-server.pdf
create-netflix-clone-03-server.pdf
 
create-netflix-clone-04-server-continued.pdf
create-netflix-clone-04-server-continued.pdfcreate-netflix-clone-04-server-continued.pdf
create-netflix-clone-04-server-continued.pdf
 
create-netflix-clone-05-client-model_transcript.pdf
create-netflix-clone-05-client-model_transcript.pdfcreate-netflix-clone-05-client-model_transcript.pdf
create-netflix-clone-05-client-model_transcript.pdf
 
create-netflix-clone-03-server_transcript.pdf
create-netflix-clone-03-server_transcript.pdfcreate-netflix-clone-03-server_transcript.pdf
create-netflix-clone-03-server_transcript.pdf
 
create-netflix-clone-02-server.pdf
create-netflix-clone-02-server.pdfcreate-netflix-clone-02-server.pdf
create-netflix-clone-02-server.pdf
 
Creating a Whatsapp Clone - Part II.pdf
Creating a Whatsapp Clone - Part II.pdfCreating a Whatsapp Clone - Part II.pdf
Creating a Whatsapp Clone - Part II.pdf
 
Creating a Whatsapp Clone - Part IX - Transcript.pdf
Creating a Whatsapp Clone - Part IX - Transcript.pdfCreating a Whatsapp Clone - Part IX - Transcript.pdf
Creating a Whatsapp Clone - Part IX - Transcript.pdf
 
Creating a Whatsapp Clone - Part II - Transcript.pdf
Creating a Whatsapp Clone - Part II - Transcript.pdfCreating a Whatsapp Clone - Part II - Transcript.pdf
Creating a Whatsapp Clone - Part II - Transcript.pdf
 
Creating a Whatsapp Clone - Part V - Transcript.pdf
Creating a Whatsapp Clone - Part V - Transcript.pdfCreating a Whatsapp Clone - Part V - Transcript.pdf
Creating a Whatsapp Clone - Part V - Transcript.pdf
 
Creating a Whatsapp Clone - Part I - Transcript.pdf
Creating a Whatsapp Clone - Part I - Transcript.pdfCreating a Whatsapp Clone - Part I - Transcript.pdf
Creating a Whatsapp Clone - Part I - Transcript.pdf
 
Creating a Whatsapp Clone - Part IX.pdf
Creating a Whatsapp Clone - Part IX.pdfCreating a Whatsapp Clone - Part IX.pdf
Creating a Whatsapp Clone - Part IX.pdf
 
Creating a Whatsapp Clone - Part VI.pdf
Creating a Whatsapp Clone - Part VI.pdfCreating a Whatsapp Clone - Part VI.pdf
Creating a Whatsapp Clone - Part VI.pdf
 
Creating a Whatsapp Clone - Part III - Transcript.pdf
Creating a Whatsapp Clone - Part III - Transcript.pdfCreating a Whatsapp Clone - Part III - Transcript.pdf
Creating a Whatsapp Clone - Part III - Transcript.pdf
 

Recently uploaded

Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
mikeeftimakis1
 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
BookNet Canada
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
Prayukth K V
 
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Nexer Digital
 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance
 
Free Complete Python - A step towards Data Science
Free Complete Python - A step towards Data ScienceFree Complete Python - A step towards Data Science
Free Complete Python - A step towards Data Science
RinaMondal9
 
GraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge GraphGraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge Graph
Guy Korland
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
Kari Kakkonen
 
FIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdfFIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance
 
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Albert Hoitingh
 
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdfSmart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
91mobiles
 
UiPath Community Day Dubai: AI at Work..
UiPath Community Day Dubai: AI at Work..UiPath Community Day Dubai: AI at Work..
UiPath Community Day Dubai: AI at Work..
UiPathCommunity
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
Aftab Hussain
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
James Anderson
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Paige Cruz
 
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
James Anderson
 
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptxSecstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
nkrafacyberclub
 
Quantum Computing: Current Landscape and the Future Role of APIs
Quantum Computing: Current Landscape and the Future Role of APIsQuantum Computing: Current Landscape and the Future Role of APIs
Quantum Computing: Current Landscape and the Future Role of APIs
Vlad Stirbu
 
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdfFIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance
 
The Future of Platform Engineering
The Future of Platform EngineeringThe Future of Platform Engineering
The Future of Platform Engineering
Jemma Hussein Allen
 

Recently uploaded (20)

Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
 
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?
 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
 
Free Complete Python - A step towards Data Science
Free Complete Python - A step towards Data ScienceFree Complete Python - A step towards Data Science
Free Complete Python - A step towards Data Science
 
GraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge GraphGraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge Graph
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
 
FIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdfFIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdf
 
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
 
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdfSmart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
 
UiPath Community Day Dubai: AI at Work..
UiPath Community Day Dubai: AI at Work..UiPath Community Day Dubai: AI at Work..
UiPath Community Day Dubai: AI at Work..
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
 
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
 
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptxSecstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
 
Quantum Computing: Current Landscape and the Future Role of APIs
Quantum Computing: Current Landscape and the Future Role of APIsQuantum Computing: Current Landscape and the Future Role of APIs
Quantum Computing: Current Landscape and the Future Role of APIs
 
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdfFIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
 
The Future of Platform Engineering
The Future of Platform EngineeringThe Future of Platform Engineering
The Future of Platform Engineering
 

Creating a Facebook Clone - Part XIV.pdf

  • 1. Creating a Facebook Clone - Part XIV
  • 2. public class Notification implements PropertyBusinessObject { public final Property<String, Notification> id = new Property<>("id"); public final Property<User, Notification> user = new Property<>("user", User.class); public final Property<String, Notification> text = new Property<>("text"); public final Property<String, Notification> reaction = new Property<>("reaction"); public final IntProperty<Notification> reactionColor = new IntProperty<>("reactionColor"); public final LongProperty<Notification> date = new LongProperty<>("date"); public final BooleanProperty<Notification> wasRead = new BooleanProperty<>("wasRead"); private final PropertyIndex idx=new PropertyIndex(this,"Notification", id, user, text, reaction, reactionColor, date, wasRead); @Override public PropertyIndex getPropertyIndex() { return idx; } } FriendsContainer
  • 3. public class Notification implements PropertyBusinessObject { public final Property<String, Notification> id = new Property<>("id"); public final Property<User, Notification> user = new Property<>("user", User.class); public final Property<String, Notification> text = new Property<>("text"); public final Property<String, Notification> reaction = new Property<>("reaction"); public final IntProperty<Notification> reactionColor = new IntProperty<>("reactionColor"); public final LongProperty<Notification> date = new LongProperty<>("date"); public final BooleanProperty<Notification> wasRead = new BooleanProperty<>("wasRead"); private final PropertyIndex idx=new PropertyIndex(this,"Notification", id, user, text, reaction, reactionColor, date, wasRead); @Override public PropertyIndex getPropertyIndex() { return idx; } } FriendsContainer
  • 4. public class Notification implements PropertyBusinessObject { public final Property<String, Notification> id = new Property<>("id"); public final Property<User, Notification> user = new Property<>("user", User.class); public final Property<String, Notification> text = new Property<>("text"); public final Property<String, Notification> reaction = new Property<>("reaction"); public final IntProperty<Notification> reactionColor = new IntProperty<>("reactionColor"); public final LongProperty<Notification> date = new LongProperty<>("date"); public final BooleanProperty<Notification> wasRead = new BooleanProperty<>("wasRead"); private final PropertyIndex idx=new PropertyIndex(this,"Notification", id, user, text, reaction, reactionColor, date, wasRead); @Override public PropertyIndex getPropertyIndex() { return idx; } } FriendsContainer
  • 5. public class Notification implements PropertyBusinessObject { public final Property<String, Notification> id = new Property<>("id"); public final Property<User, Notification> user = new Property<>("user", User.class); public final Property<String, Notification> text = new Property<>("text"); public final Property<String, Notification> reaction = new Property<>("reaction"); public final IntProperty<Notification> reactionColor = new IntProperty<>("reactionColor"); public final LongProperty<Notification> date = new LongProperty<>("date"); public final BooleanProperty<Notification> wasRead = new BooleanProperty<>("wasRead"); private final PropertyIndex idx=new PropertyIndex(this,"Notification", id, user, text, reaction, reactionColor, date, wasRead); @Override public PropertyIndex getPropertyIndex() { return idx; } } FriendsContainer
  • 6. return null; } public static List<Notification> fetchNotifications( long since, int amount) { if(since < initTime - UIUtils.DAY) { return null; } List<Notification> response = new ArrayList<>(); response.add(new Notification().id.set("Notify-1"). user.set(dummyUsers[0]). text.set("liked Your Post"). date.set(initTime - 60000). reaction.set("" + FontImage.MATERIAL_FAVORITE). reactionColor.set(0xff0000)); response.add(new Notification().id.set("Notify-2"). user.set(dummyUsers[1]). text.set("commented on your post"). date.set(initTime - 600000000). reaction.set("" + FontImage.MATERIAL_CHAT). reactionColor.set(0xff00)); return response; } ServerAPI
  • 7. return null; } public static List<Notification> fetchNotifications( long since, int amount) { if(since < initTime - UIUtils.DAY) { return null; } List<Notification> response = new ArrayList<>(); response.add(new Notification().id.set("Notify-1"). user.set(dummyUsers[0]). text.set("liked Your Post"). date.set(initTime - 60000). reaction.set("" + FontImage.MATERIAL_FAVORITE). reactionColor.set(0xff0000)); response.add(new Notification().id.set("Notify-2"). user.set(dummyUsers[1]). text.set("commented on your post"). date.set(initTime - 600000000). reaction.set("" + FontImage.MATERIAL_CHAT). reactionColor.set(0xff00)); return response; } ServerAPI
  • 8. return null; } public static List<Notification> fetchNotifications( long since, int amount) { if(since < initTime - UIUtils.DAY) { return null; } List<Notification> response = new ArrayList<>(); response.add(new Notification().id.set("Notify-1"). user.set(dummyUsers[0]). text.set("liked Your Post"). date.set(initTime - 60000). reaction.set("" + FontImage.MATERIAL_FAVORITE). reactionColor.set(0xff0000)); response.add(new Notification().id.set("Notify-2"). user.set(dummyUsers[1]). text.set("commented on your post"). date.set(initTime - 600000000). reaction.set("" + FontImage.MATERIAL_CHAT). reactionColor.set(0xff00)); return response; } ServerAPI
  • 9. © Codename One 2017 all rights reserved
  • 10. public class NotificationsContainer extends InfiniteContainer { private long lastTime; @Override public Component[] fetchComponents(int index, int amount) { if(index == 0) { lastTime = System.currentTimeMillis(); } List<Notification> response = ServerAPI.fetchNotifications(lastTime, amount); if(response == null) { return null; } Component[] notifications = new Component[response.size()]; int iter = 0; for(Notification n : response) { lastTime = n.date.getLong(); notifications[iter] = createNotificationEntry(n); iter++; } NotificationsContainer
  • 11. public class NotificationsContainer extends InfiniteContainer { private long lastTime; @Override public Component[] fetchComponents(int index, int amount) { if(index == 0) { lastTime = System.currentTimeMillis(); } List<Notification> response = ServerAPI.fetchNotifications(lastTime, amount); if(response == null) { return null; } Component[] notifications = new Component[response.size()]; int iter = 0; for(Notification n : response) { lastTime = n.date.getLong(); notifications[iter] = createNotificationEntry(n); iter++; } NotificationsContainer
  • 12. notifications[iter] = createNotificationEntry(n); iter++; } return notifications; } private Container createNotificationEntry(Notification n) { Image avatar = n.user.get().getAvatar(13); Label icon = new Label("", "SmallBlueCircle"); icon.getAllStyles().setBorder(RoundBorder.create(). color(n.reactionColor.get())); FontImage.setMaterialIcon(icon, n.reaction.get().charAt(0), 2); Container avatarContainer = LayeredLayout.encloseIn( new Label(avatar, "HalfPaddedContainer"), FlowLayout.encloseRightBottom(icon)); RichTextView rt = new RichTextView("<b>" + n.user.get().fullName() + "</b> " + n.text.get()); Label time = new Label(UIUtils.formatTimeAgo(n.date.get()), "SmallBlueLabel"); Container yContainer = BoxLayout.encloseY(rt, time); yContainer.setUIID("HalfPaddedContainer"); return BorderLayout. centerEastWest(yContainer, null, avatarContainer); } NotificationsContainer
  • 13. notifications[iter] = createNotificationEntry(n); iter++; } return notifications; } private Container createNotificationEntry(Notification n) { Image avatar = n.user.get().getAvatar(13); Label icon = new Label("", "SmallBlueCircle"); icon.getAllStyles().setBorder(RoundBorder.create(). color(n.reactionColor.get())); FontImage.setMaterialIcon(icon, n.reaction.get().charAt(0), 2); Container avatarContainer = LayeredLayout.encloseIn( new Label(avatar, "HalfPaddedContainer"), FlowLayout.encloseRightBottom(icon)); RichTextView rt = new RichTextView("<b>" + n.user.get().fullName() + "</b> " + n.text.get()); Label time = new Label(UIUtils.formatTimeAgo(n.date.get()), "SmallBlueLabel"); Container yContainer = BoxLayout.encloseY(rt, time); yContainer.setUIID("HalfPaddedContainer"); return BorderLayout. centerEastWest(yContainer, null, avatarContainer); } NotificationsContainer
  • 14. notifications[iter] = createNotificationEntry(n); iter++; } return notifications; } private Container createNotificationEntry(Notification n) { Image avatar = n.user.get().getAvatar(13); Label icon = new Label("", "SmallBlueCircle"); icon.getAllStyles().setBorder(RoundBorder.create(). color(n.reactionColor.get())); FontImage.setMaterialIcon(icon, n.reaction.get().charAt(0), 2); Container avatarContainer = LayeredLayout.encloseIn( new Label(avatar, "HalfPaddedContainer"), FlowLayout.encloseRightBottom(icon)); RichTextView rt = new RichTextView("<b>" + n.user.get().fullName() + "</b> " + n.text.get()); Label time = new Label(UIUtils.formatTimeAgo(n.date.get()), "SmallBlueLabel"); Container yContainer = BoxLayout.encloseY(rt, time); yContainer.setUIID("HalfPaddedContainer"); return BorderLayout. centerEastWest(yContainer, null, avatarContainer); } NotificationsContainer
  • 15. notifications[iter] = createNotificationEntry(n); iter++; } return notifications; } private Container createNotificationEntry(Notification n) { Image avatar = n.user.get().getAvatar(13); Label icon = new Label("", "SmallBlueCircle"); icon.getAllStyles().setBorder(RoundBorder.create(). color(n.reactionColor.get())); FontImage.setMaterialIcon(icon, n.reaction.get().charAt(0), 2); Container avatarContainer = LayeredLayout.encloseIn( new Label(avatar, "HalfPaddedContainer"), FlowLayout.encloseRightBottom(icon)); RichTextView rt = new RichTextView("<b>" + n.user.get().fullName() + "</b> " + n.text.get()); Label time = new Label(UIUtils.formatTimeAgo(n.date.get()), "SmallBlueLabel"); Container yContainer = BoxLayout.encloseY(rt, time); yContainer.setUIID("HalfPaddedContainer"); return BorderLayout. centerEastWest(yContainer, null, avatarContainer); } NotificationsContainer
  • 16. SmallBlueLabel { color: blue; font-size: 2mm; padding: 1mm; font-family: "native:MainLight"; } theme.css