JdbcUrl

public class JdbcUrl

Represents a JDBC URL, allows getting the url or database name parts. Support primarily Postgresql and MySQL.

Constructors

JdbcUrl

public JdbcUrl(String url)

Constructs this from the provided url.

Parameters:
  • url – the url to constructs this object from
Throws:
  • URISyntaxException – if the url is invalid

Methods

getDbName

public String getDbName()
Returns:the name of the database from this url

getUrlForDbServer

public String getUrlForDbServer()
Returns:get an url for connecting with the server without the database part

getValue

public String getValue()
Returns:returns the entire url