Skip to content

Initialize columnNameToIndexMap when accessed by client code #116

Merged
merged 1 commit into from Jan 31, 2013

2 participants

@danieldickison

Lazily create and populate the dictionary when calling -columnNameToIndexMap so that it can be used directly before column values have been accessed. Among other things, this makes it possible to check whether a column exists in a results set (see issue #79).

This does change the property from (atomic, retain) to (readonly), so it will break code that sets this property directly instead of modifying the fmdb-provided dictionary. That seems like a strange use-case to me, but perhaps there's a situation where it is useful that I'm missing.

@danieldickison danieldickison Lazily populate columnNameToIndexMap when accessing so that clients c…
…an use the value without causing setupColumns to be called first.
d72cbb0
@ccgus ccgus merged commit d72cbb0 into ccgus:master Jan 31, 2013
@ccgus
Owner
ccgus commented Jan 31, 2013

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.