Changed static methods to instance methods to allow customisation of output arrays/dictionaries.