Class BackendSqlPlatform
java.lang.Object
com.codename1.db.sql.SqlPlatform
com.codename1.backend.BackendSqlPlatform
The server's
SqlPlatform: connections over Tcp, randomness and key
derivation from Crypto, and the server's own exception types, so a
repository catches the same ConcurrencyFailureException and
DataIntegrityViolationException whichever engine raised them.-
Method Summary
Modifier and TypeMethodDescriptionconcurrencyFailure(String message) The exception for a transaction that can be run again.Opens a plain TCP connection.static voidinstall()Installs the server platform.integrityViolation(String message) The exception for a write a constraint refused.byte[]byte[]randomBytes(int length) lengthbytes from a cryptographically secure source.withMessage(IOException failure, String message) failureagain withmessage, keeping what kind of failure it is.Methods inherited from class SqlPlatform
get, install
-
Method Details
-
install
public static void install()Installs the server platform.Databasedoes this when it is first used; code that opens a wire client directly calls it first. -
connect
Description copied from class:SqlPlatformOpens a plain TCP connection.- Specified by:
connectin classSqlPlatform- Throws:
IOException
-
randomBytes
Description copied from class:SqlPlatformlengthbytes from a cryptographically secure source.- Specified by:
randomBytesin classSqlPlatform- Throws:
IOException
-
pbkdf2
public byte[] pbkdf2(String digest, byte[] password, byte[] salt, int iterations, int length) throws IOException Description copied from class:SqlPlatform- Overrides:
pbkdf2in classSqlPlatform- Throws:
IOException
-
concurrencyFailure
Description copied from class:SqlPlatformThe exception for a transaction that can be run again.- Overrides:
concurrencyFailurein classSqlPlatform
-
integrityViolation
Description copied from class:SqlPlatformThe exception for a write a constraint refused.- Overrides:
integrityViolationin classSqlPlatform
-
withMessage
Description copied from class:SqlPlatformfailureagain withmessage, keeping what kind of failure it is.- Overrides:
withMessagein classSqlPlatform
-