class NewAssetHandlerCardWidget {

    public void initialize(NewResourceHandler resourceHandler) {
        ResourceTypeDefinition resourceType = resourceHandler.getResourceType();
        this.view.init(this);
        this.view.setTitle(resourceHandler.getDescription());
        if (resourceType.getCategory() != null) {
            this.view.setDescription(ts.getTranslation(resourceType.getCategory().getName()));
        }
        if (resourceHandler.getIcon() != null) {
            this.view.setIcon(elemental2DomUtil.asHTMLElement(resourceHandler.getIcon().asWidget().getElement()));
        }
        this.view.setCommand(resourceHandler.getCommand(newResourcePresenter));
    }

    @Inject public  NewAssetHandlerCardWidget(final NewAssetHandlerCardWidget.View view,
                                     final NewResourcePresenter newResourcePresenter,
                                     final TranslationService ts);

}