class InputControlResourceValidator extends GenericResourceValidator<InputControl> {

    @PostConstruct
    public void initialize() {
        try {
            PropertyDescriptor[] availableProperties = Introspector.getBeanInfo(InputControl.class).getPropertyDescriptors();
            for (PropertyDescriptor descriptor : availableProperties) {
                if (Object.class.isAssignableFrom(descriptor.getPropertyType()) && descriptor.getReadMethod() != null && descriptor.getWriteMethod() != null) {
                    properties.put(descriptor.getName(), descriptor);
                }
            }

            for (String key : inputControlTypeConfiguration.keySet()) {
                String required = (String) inputControlTypeConfiguration.get(key).get(PROPERTY_REQUIRED);
                if (required != null) {
                    for (String definedName : required.split(PROPERTY_REQUIRED_SEPARATOR)) {
                        if (!properties.containsKey(definedName)) {
                            StringBuilder message = new StringBuilder("The input control type ").append(key)
                                    .append(" contains unknown property '").append(definedName).append("'\n")
                                    .append("Valid values:\n");
                            for (String name : properties.keySet()) {
                                message.append("'").append(name).append("',\n");
                            }

                            throw new IllegalStateException(message.toString());
                        }
                    }
                }
            }
        } catch (IntrospectionException e) {
            throw new IllegalStateException("Introspection error", e);
        }
    }

}