Converts an object into a one dimensional object with its attributes keys separated by . or another separator