• Stars
    star
    537
  • Rank 82,649 (Top 2 %)
  • Language
    Objective-C
  • License
    MIT License
  • Created over 15 years ago
  • Updated almost 8 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

EGODatabase is a thread-safe Objective-C SQLite wrapper with full support for asynchronous SQLite calls as well as built in NSOperationQueue support.

About EGODatabase

EGODatabase is a thread-safe Objective SQLite wrapper created by enormego. After extensively using FMDB in our applications, we saw a lot of room for improvements, the biggest was making it thread-safe. EGODatabase uses some code from FMDB, but for the most part, it was completely reworked to use result sets and row objects. A major difference between FMDB and EGODatabase is when selecting data, EGODatabase populates its EGODatabaseRow class with the data from SQLite, as opposed to retaining the SQLite results like FMDB does.

EGODatabase is tested to work with with all versions of iOS and Mac OS X 10.5+.

Classes

EGODatabase

This is the class where you'll open your SQLite database file and execute queries through.

EGODatabaseResult

This is the class returned by EGODatabase when running "executeQuery:". It supports fast enumeration, and contains properties for the column names, column types, rows, and errors if there are any.

EGODatabaseRow

Every object that EGODatabaseResult contains, is an EGODatabaseRow. This is your raw data for each row. You'll be able to return specific types based on different methods such as intForColumn: or dateForColumn:. Check out the header files for a complete listing.

Documentation

Check out each header file for a complete listing of each method.

Example

EGODatabase* database = [EGODatabase databaseWithPath:[NSHomeDirectory() stringByAppendingPathComponent:@"Documents/database.db"]];
EGODatabaseResult* result = [database executeQueryWithParameters:@"SELECT * FROM `posts` WHERE `user_id` = ?", @(10), nil];
for(EGODatabaseRow* row in result) {
	NSLog(@"Subject: %@", [row stringForColumn:@"subject"]);
	NSLog(@"Date: %@", [row dateForColumn:@"date"]);
	NSLog(@"Views: %d", [row intForColumn:@"views"]);
	NSLog(@"Message: %@", [row stringForColumn:@"message"]);
}

Note

Remember to link libsqlite3.dylib to your project!

More Repositories

1

EGOTableViewPullRefresh

A similar control to the pull down to refresh control created by atebits in Tweetie 2.
Objective-C
3,264
star
2

EGOCache

Fast Caching for Objective-C (iPhone & Mac Compatible)
Objective-C
1,331
star
3

EGOImageLoading

What if images on the iPhone were as easy as HTML?
Objective-C
801
star
4

cocoa-helpers

A collection of helpers (categories) we've written for iOS and OS X, full with convenience methods to make them easier and more useful. [tags:cocoa,objective-c,ios,mac]
Objective-C
748
star
5

EGOTextView

EGOTextView is a complete drop in replacement for UITextView created by enormego, that adds support for Rich Text Editing. [tags:ios,objective-c,uitextview]
Objective-C
733
star
6

PhotoViewer

Quick PhotoViewer for the iPhone. Built upon our other reliable libraries: EGOImageLoading and EGOCache.
Objective-C
660
star
7

flicktabcontrol

FlickTabControl is an easy to use library of the "Flick" tab bar, originally inspired by the implementation of tabbing in Facebook's iPhone application. [tags:iphone,objective-c]
Objective-C
211
star
8

EGOTextMateFullScreen

A TextMate Plugin that adds native full screen app support for Mac OS X Lion users.
Objective-C
185
star
9

ABTableViewCell

Objective-C
174
star
10

askit

ASKit is an easy to use library for your iOS applications. ASKit provides AppStore styled table views [tags:ios,appstore,objective-c]
Objective-C
166
star
11

UIKit

Port of iPhone's UIKit for Mac OS X
Objective-C
96
star
12

EGOTextFieldAlertView

UIAlertView subclass that adds support for UITextFields, without using any private methods.
88
star
13

EGOGradientView

CAGradientLayer backed UIView, with pass-through properties
Objective-C
66
star
14

EGOHTTPRequest

Useful wrapper around NSURLConnection that adds many essential methods
Objective-C
58
star
15

EGOUICache

Quickly cache drawRect methods to images, to avoid unnecessarily repeating intensive drawings every time.
Objective-C
50
star
16

Voice

Native iPhone App wrapper around the Google Voice iPhone Web App [nolist]
Objective-C
49
star
17

EGOViewStackPersistence

Objective-C
26
star
18

EightPHP

Eight is a PHP5 framework branched from KohanaPHP that uses the Model View Controller architectural pattern. [tags:php,php5,frameworks]
PHP
25
star
19

XcodePHP

Better PHP support for Xcode. Full auto-complete macros, keywords, the works.
24
star
20

EGOProcessName

EGOProcessName is a PHP5 extension that allows you to change the process name of the currently running PHP process.
C
5
star
21

EGOPageControl

Drop in replacement for UIPageControl with support for custom page icons
3
star
22

MAMP-PHP-Extensions

Some PHP extensions built for MAMP.
2
star