setting the style to Notification object


i am using to the below code to display the errors

new Notification(" Correct Errors ", notificationData, Notification.Type.ERROR_MESSAGE, true).show(Page.getCurrent());

if i use old Notifcation style then i have the method called setStyleName , but above code how to apply style as i did not have any method to set that

You could use:

    Notification notification = new Notification("Correct Errors ", desc, Notification.Type.ERROR_MESSAGE, true);

thanks,its working