/** * Reads the listing specific state from the given design. * <p> * This method is separated from {@link #readDesign(Element, DesignContext)} * to be overridable in subclasses that need to replace this, but still must * be able to call {@code super.readDesign(...)}. * * @see #doWriteDesign(Element, DesignContext) * * @param design * The element to obtain the state from * @param context * The DesignContext instance used for parsing the design */ protected void doReadDesign(Element design, DesignContext context) { Attributes attr = design.attributes(); if (attr.hasKey("readonly")) { setReadOnly(DesignAttributeHandler.readAttribute("readonly", attr, Boolean.class)); } setItemCaptionGenerator( new DeclarativeCaptionGenerator<>(getItemCaptionGenerator())); setItemIconGenerator( new DeclarativeIconGenerator<>(getItemIconGenerator())); readItems(design, context); }