@API.Public @API.Factory public final class DriverManager extends Object
| Modifier and Type | Field and Description |
|---|---|
static Pattern |
OJAI_PROTOCOL_PATTERN
Pattern for OJAI Connection URLs.
|
| Constructor and Description |
|---|
DriverManager() |
| Modifier and Type | Method and Description |
|---|---|
static Connection |
getConnection(String url)
Establishes and returns a Connection to an OJAI data source.
|
static Connection |
getConnection(String url,
Document options)
Establishes and returns a Connection to an OJAI data source.
|
static Driver |
getDriver(String url)
Discovers and loads the OJAI Driver implementation which supported the
specified URL.
|
static void |
registerDriver(Driver driver)
Registers the specified Driver with this DriverManager.
|
public static final Pattern OJAI_PROTOCOL_PATTERN
Pattern for OJAI Connection URLs.
public static Driver getDriver(@API.NonNullable String url) throws OjaiException
url - a URL of the form "ojai:NullPointerException - if the specified URL is nullIllegalArgumentException - if the specified URL does does not begin with "ojai:"OjaiException - if no registered driver for found for the specified URLpublic static Connection getConnection(@API.NonNullable String url) throws OjaiException
url - a URL of the form "ojai:NullPointerException - if the specified URL is nullIllegalArgumentException - if the specified URL does does not begin with "ojai:"OjaiException - if no registered driver for found for the specified URLStoreException - if connection to the data-source failedpublic static Connection getConnection(@API.NonNullable String url, @API.NonNullable Document options) throws OjaiException
url - a URL of the form "ojai:options - an OJAI Document of arbitrary, implementation specific settingsNullPointerException - if the specified URL is nullIllegalArgumentException - if the specified URL does does not begin with "ojai:"OjaiException - if no registered driver for found for the specified URLStoreException - if connection to the data-source failed@API.Internal public static void registerDriver(@API.NonNullable Driver driver)
Copyright © 2015–2018 MapR Technologies, Inc.. All rights reserved.