I am using ToolBar in my project first time, so i do not know how to customized the toolbar in android. I need to centered title in to the tool bar and how to do that please
Remember that Toolbar is just a ViewGroup like the others. So you can stuff Views into it. In your case, you need a TextView inside a Toolbar.
Now, set the Toolbar as your action bar by first retrieving it and then using the setSupportActionBar().
Since the gravity of the TextView is set to center, the text must be centered.