public CamelContextsPage()

in camel/src/main/java/org/apache/karaf/webconsole/camel/internal/context/CamelContextsPage.java [53:79]


    public CamelContextsPage() {
        @SuppressWarnings("serial")
        IColumn<CamelContext, String>[] columns = new IColumn[] {
            new OrdinalColumn<CamelContext>(),
            new PropertyColumnExt<CamelContext>("Name", "name"),
            new PropertyColumnExt<CamelContext>("Version", "version"),
            new PropertyColumnExt<CamelContext>("Status", "status"),
            new PropertyColumnExt<CamelContext>("Uptime", "uptime"),
            new AbstractColumn<CamelContext, String>(Model.of("Message preview")) {
                public void populateItem(Item<ICellPopulator<CamelContext>> cellItem, String componentId, IModel<CamelContext> rowModel) {
                    cellItem.add(new Label(componentId, "" + container.isTracePossible(rowModel.getObject())));
                }
            },
            new AbstractColumn<CamelContext, String>(Model.of("Tracing enabled")) {
                public void populateItem(Item<ICellPopulator<CamelContext>> cellItem, String componentId, IModel<CamelContext> rowModel) {
                    cellItem.add(new Label(componentId, "" + container.isTraced(rowModel.getObject())));
                }
            },
            new AbstractColumn<CamelContext, String>(Model.of("Operations")) {
                public void populateItem(Item<ICellPopulator<CamelContext>> cellItem, String componentId, IModel<CamelContext> rowModel) {
                    cellItem.add(new ContextActionsPanel(componentId, rowModel));
                }
            }
        };

        add(new BaseDataTable<CamelContext>("contexts", Arrays.asList(columns), new CamelContextsDataProvider(contexts), 20));
    }