Add API for duplicating a collection (bug 906186)

https://bugzilla.mozilla.org/show_bug.cgi?id=906186