Populate an instance created by given factory using a given put(key,value) method.
If the first argument of the given put method is integer then fill the values
by index else fill the values with alias key.