public static BundleWiringDTO newBundleWiringDTO(BundleRevision revision) {
   if (revision == null) {
     return null;
   }
   BundleWiringDTO dto = new DTOBuilder().getBundleWiringDTO(revision.getWiring());
   return dto;
 }
 private BundleRevisionDTO getBundleRevisionDTO(BundleRevision revision) {
   if (revision == null) {
     return null;
   }
   BundleRevisionDTO dto = resources.get(revision);
   if (dto != null) {
     return dto;
   }
   dto = new BundleRevisionDTO();
   dto.id = identifier(revision);
   resources.put(revision, dto);
   dto.bundle = revision.getBundle().getBundleId();
   dto.symbolicName = revision.getSymbolicName();
   dto.type = revision.getTypes();
   dto.version = revision.getVersion().toString();
   dto.capabilities = getListCapabilityDTO(revision.getDeclaredCapabilities(null));
   dto.requirements = getListRequirementDTO(revision.getDeclaredRequirements(null));
   return dto;
 }