Incompleted wiki while creating your own Dialog
AngeloAvv opened this issue · 3 comments
Hi, in this wiki the instructions are not complete. If you don't create your own builder which instantiates your custom class, the Dialog will show an empty view. In my case I added:
public static JustifyDialog build() {
return new JustifyDialog();
}
to solve the problem. This should be a mandatory instruction, maybe could save other's people time
Sure, nothing else is to be expected as you are calling the build
method of SimpleDialog
then.
I expected people to realise this right away (or call the constructor directly), but you are totally right it's missing in the wiki (sorry having wasted your time :/). I just added it to the wiki. Thanks for your feedback.
What do you think about adding the following to CustomViewDialog
? This will hopefully save other people's time as well.
public static CustomViewDialog build(){
throw new java.lang.InstantiationError("Unintended abuse of the builder method. " +
"Have you created your own build() method in your custom dialog?");
}
Well it could be a good practice throwing an exception if someone uses the builder but doesn't call the right one. Anyway don't feel sorry about that, we're here to help each other :)
BTW I just need to say thank you about this wonderful library, I do really appreciate your work 👍
Thanks :)