public UserCodeNamespaceConfig addClass(@Nonnull Class<?>... classes) {
        Objects.requireNonNull(classes, "Classes cannot be null");
        ResourceConfig.fromClass(classes).map(ResourceDefinitionImpl::new)
                .forEach(resourceDefinition -> resourceDefinitions.put(resourceDefinition.id(), resourceDefinition));
        return this;
    }
@Test
    public void testAddClass() {
        Class<?> clazz = Person.class;
        userCodeNamespaceConfig.addClass(clazz);
        ClassLoader cl = clazz.getClassLoader();
        assertNotNull(clazz.getName() + ".getClassLoader() returned null", cl);
        String classResourceId = toClassResourceId(clazz.getName());

        long matches = userCodeNamespaceConfig.getResourceConfigs().stream()
                                              .filter(rc -> rc.type() == ResourceType.CLASS)
                                              .filter(rc -> rc.id().equals(classResourceId))
                                              .filter(rc -> rc.url().equals(cl.getResource(classResourceId).toString()))
                                              .count();
        assertEquals(1, matches);
    }