Added getLibraries method to dynamically get the library names.