Use neo4j java driver to connect neo4j DB by database name

Can I have an example of java application connecting to neo4j database by specifying a database name? I have multiple databases but need to connect to only one.

This is what I have now, it works but only connects to default neo4j database, and I need to connect to another database:
spring.data.neo4j.uri=neo4j://localhost:7687
spring.data.neo4j.username=neo4j
spring.data.neo4j.password=xxxxxx

@adellalin You need to specify the database name as parameter while creating the session like driver.session( database=XXXX)