Classes
The following classes are available globally.
-
The entity that has authority to use a store MySQL.
See moreDeclaration
Objective-C
@interface OHMySQLConfiguration : NSObject
Swift
class MySQLConfiguration : NSObject
-
An instance of OHMySQLQueryRequest describes SQL query used to retrieve data from a MySQL store.
See moreDeclaration
Objective-C
@interface OHMySQLQueryRequest : NSObject
Swift
class MySQLQueryRequest : NSObject
-
An instance of OHMySQLTimeline represents lifecycle of the query.
See moreDeclaration
Objective-C
@interface OHMySQLQueryTimeline : NSObject
Swift
class MySQLQueryTimeline : NSObject
-
An object of this class contains details about a store MySQL.
See moreDeclaration
Objective-C
@interface OHMySQLStore : NSObject
Swift
class MySQLStore : NSObject
-
This class is used for establishing secure connections using SSL.
Note
Please, see http://dev.mysql.com/doc/refman/5.7/en/mysql-ssl-set.html for more details.Declaration
Objective-C
@interface OHSSLConfig : NSObject
Swift
class MySQLSSLConfig : NSObject
-
Represents a main context and store coordinator.
See moreDeclaration
Objective-C
@interface OHMySQLContainer : NSObject
Swift
class MySQLContainer : NSObject
-
An instance of this class is responsible for executing queries, saving/updating/deleting objects.
See moreDeclaration
Objective-C
@interface OHMySQLQueryContext : NSObject
Swift
class MySQLQueryContext : NSObject
-
Convenience class for making specific OHMySQLQueryRequest instances.
See moreDeclaration
Objective-C
@interface OHMySQLQueryRequestFactory : NSObject
Swift
class MySQLQueryRequestFactory : NSObject
-
Undocumented
See moreDeclaration
Objective-C
@interface OHMySQLStoreCoordinator : NSObject /// Nonnull after connection with DB. @property (nonatomic, strong, readonly, nullable) OHMySQLStore *store; /// Nonnull after connection with DB. @property (nonatomic, strong, readonly, nullable) OHMySQLConfiguration *configuration; /// Nonnull after connection with DB. You don't need to use this property at all. @property (readonly, nullable) void *mysql NS_REFINED_FOR_SWIFT; /// Pings the server and indicates whether the connection to the server is working. @property (assign, readonly, getter=isConnected) BOOL connected; /// One of the protocols. Needs to be set before calling -connect. @property (nonatomic, assign) OHProtocolType protocol; /// The default character set for the current connection. By default UTF-8. @property (nonatomic, assign) CharsetEncoding encoding; - (nonnull instancetype)initWithConfiguration:(nonnull OHMySQLConfiguration *)configuration; /// Attempts to disconnect and then establish a connection to a MySQL database engine. Also tries establish SSL connection if it is specified. - (BOOL)reconnect; /// Attempts to establish a connection to a MySQL database engine. Also tries establish SSL connection if it is specified. - (BOOL)connect; /** * @param database Name of the target db. * * @return Zero for success. Nonzero if an error occurred (see enum). */ - (OHResultErrorType)selectDataBase:(nonnull NSString *)database; /// Closes a previously opened connection. - (void)disconnect; /** * Asks the database server to shut down. The connected user must have the SHUTDOWN privilege. * * @return Zero for success. Nonzero if an error occurred. */ - (OHResultErrorType)shutdown; /** * Flushes tables or caches, or resets replication server information. The connected user must have the RELOAD privilege. * * @param options A bit mask composed from any combination. * * @return Zero for success. Nonzero if an error occurred (see enum). */ - (OHResultErrorType)refresh:(OHRefreshOption)options; /** * Checks whether the connection to the server is working. If the connection has gone down and auto-reconnect is enabled an attempt to reconnect is made. * * @return Zero if the connection to the server is active. Nonzero if an error occurred. A nonzero return does not indicate whether the MySQL server itself is down; the connection might be broken for other reasons such as network problems. */ - (OHResultErrorType)pingMySQL __attribute__((warn_unused_result)); @end
Swift
class MySQLStoreCoordinator : NSObject