Add support for wrapArray.elementName being a function

So the child names can be determined by the name of the parent.

Example:

```javascript
js2xmlparser("root", data, {
  wrapArray: {
    enabled: true,
    elementName: function (parent) { 
      return singularize(parent);
    }
  }
});
```