/** * @param bundle The bundle this def entry belongs to. * @param zipEntry The ZipEntry representing the def-file. */ public DefEntry(Bundle bundle, ZipEntry zipEntry) { this.bundle = bundle; this.zipEntry = zipEntry; String entryName = zipEntry.getName(); Tuple2<String, String> nameAndNamespace = ConfigUtils.getNameAndNamespaceFromString(entryName.substring(DEFPATH.length(), entryName.indexOf(".def"))); defName = nameAndNamespace.first; defNamespace = getNamespace(); if (defNamespace.isEmpty()) throw new IllegalArgumentException("Config definition '" + defName + "' is missing a package (or namespace)"); contents = getContents(); }