add mrn_open and some refactoring.
add mrn_open and some refactoring.

mroonga/mroonga,mroonga/mroonga,yoku0825/mroonga,yoku0825/mroonga,mroonga/mroonga,naoa/mroonga,yoku0825/mroonga,naoa/mroonga,yoku0825/mroonga,yoku0825/mroonga,naoa/mroonga,naoa/mroonga,yoku0825/mroonga,mroonga/mroonga,naoa/mroonga,naoa/mroonga