Container implements LayoutEditorElement { Supplier<LayoutTemplate> createCurrentLayoutTemplateSupplier() { return () -> toLayoutTemplate(); } @Inject  Container(final View view,
                     LayoutEditorCssHelper layoutCssHelper,
                     Instance<Row> rowInstance,
                     Instance<EmptyDropRow> emptyDropRowInstance,
                     Event<ComponentDropEvent> componentDropEvent,
                     Event<LayoutEditorElementSelectEvent> containerSelectEvent,
                     Event<LayoutEditorElementUnselectEvent> containerUnselectEvent,
                     Event<LockRequiredEvent> lockRequiredEvent,
                     DnDManager dndManager,
                     LayoutEditorFocusController layoutEditorFocusController); @PostConstruct void setup(); @PreDestroy void preDestroy(); void setLockSupplier(Supplier<Boolean> lockSupplier); @Override String getId(); @Override LayoutEditorElementType geElementType(); @Override LayoutEditorElement getParentElement(); @Override void setSelectable(boolean selectable); boolean isSelectable(); @Override boolean isSelected(); @Override void setSelected(boolean status); void loadEmptyLayout(String layoutName,
                                LayoutTemplate.Style pageStyle,
                                String emptyTitleText,
                                String emptySubTitleText); void load(LayoutTemplate layoutTemplate,
                     String emptyTitleText,
                     String emptySubTitleText); void reset(); ParameterizedCommand<RowDrop> createEmptyDropCommand(); Supplier<Boolean> getLockSupplier(); ParameterizedCommand<RowDrop> createRowDropCommand(); String getLayoutName(); void addProperty(String key,
                            String value); String getProperty(String key); @Override Map<String, String> getProperties(); @Override void setProperty(String property, String value); @Override void removeProperty(String property); @Override void clearProperties(); @Override List<PropertyEditorCategory> getPropertyCategories(); LayoutTemplate toLayoutTemplate(); List<Row> getRows(); View getView(); void resizeRows(@Observes RowResizeEvent resize); LayoutTemplate.Style getPageStyle(); void onSelected(); List<Row> getChildElements();  }
@Test public void createCurrentLayoutTemplateSupplierTest() throws Exception { LayoutTemplate expected = loadLayout(SAMPLE_FULL_FLUID_LAYOUT); LayoutTemplate toLayoutTemplate = container.toLayoutTemplate(); Supplier<LayoutTemplate> currentLayoutTemplateSupplier = container.createCurrentLayoutTemplateSupplier(); assertEquals(expected, toLayoutTemplate); assertEquals(expected, currentLayoutTemplateSupplier.get()); }