zendesk / android-db-commons

Some common utilities for ContentProvider/ContentResolver/Cursor and other db-related android stuff
Apache License 2.0
222 stars 28 forks source link

CursorLoaderBuilder API changes #42

Closed chalup closed 10 years ago

chalup commented 10 years ago

Tl;dr: I'd like to make two changes:

  1. Rename transform to transformRows.
  2. Rename wrap to transform.

Let's talk about wrap and transform methods names. The latter is actually not bad, because it really transforms the Cursor into something else, but wrap name would make more sense for a method with Function<Cursor, Cursor> wrapper signature, which suggests using a CursorWrapper (BTW: see #23). IMO a better name for current wrap functionality would be transform, but this means we have to rename current transform to something else; transformRows is the best name I can think of.

It is a breaking API change, which will be a source of inconvenience for the current users of the library, but I think it's worth to polish the API before v1.0 release, which by definition promises stability. Let's nail down this API, so if you have a better idea for the names of these methods, speak now (or forever hold your peace).

chalup commented 10 years ago

I'm going to start working on this one in the next few days. Speak now or forever hold your peace.

chalup commented 10 years ago

Done in #46