I have an app that displays the default activity as:

When clicked the hamburger icon opens left main navigation drawer as:

And when clicked the FILTER button opens another drawer from the right as:

I know how the left navigation drawer is displayed (all java codes and layouts)
What is the code for displaying the drawer that is opening from the right ?
and also i wanna know, how the on click listener is set up even if the FILTER button is outside the toolbar ?
Can anyone help?
Just change the value of
tools:openDrawerto end (i.etools:openDrawer="end"), also addandroid:layout_gravity="end"in<android.support.design.widget.NavigationView>. Here's the solution.activity_main.xml
MainActivity.java