ComponentBase extends UifDictionaryBeanBase implements Component { @Override public String getSimpleDataAttributes() { String attributes = ""; if (getDataAttributes() == null) { return attributes; } for (Map.Entry<String, String> data : getDataAttributes().entrySet()) { if (data != null && data.getValue() != null) { attributes = attributes + " " + "data-" + data.getKey() + "=\"" + KRADUtils.convertToHTMLAttributeSafeString(data.getValue()) + "\""; } } return attributes; } ComponentBase(); @Override boolean skipLifecycle(); void checkMutable(boolean legalDuringInitialization); boolean isMutable(boolean legalDuringInitialization); String getViewStatus(); @Override void setViewStatus(String status); @Override void notifyCompleted(ViewLifecyclePhase phase); boolean isInitialized(); boolean isModelApplied(); boolean isFinal(); boolean isRendered(); @Override void performInitialization(Object model); @Override void performApplyModel(Object model, LifecycleElement parent); @Override void afterEvaluateExpression(); @Override void performFinalize(Object model, LifecycleElement parent); @ViewLifecycleRestriction List<Component> getPropertyReplacerComponents(); @BeanTagAttribute @Override String getId(); @Override void setId(String id); @Override String getContainerIdSuffix(); @Override void setContainerIdSuffix(String containerIdSuffix); @Override String getViewPath(); @Override void setViewPath(String viewPath); @Override Map<String, String> getPhasePathMapping(); @Override void setPhasePathMapping(Map<String, String> phasePathMapping); @BeanTagAttribute @Override String getTemplate(); @Override void setTemplate(String template); @Override List<String> getAdditionalTemplates(); @BeanTagAttribute @Override String getTemplateName(); @Override void setTemplateName(String templateName); @BeanTagAttribute @Override String getTitle(); @Override void setTitle(String title); @BeanTagAttribute @Override boolean isHidden(); @Override void setHidden(boolean hidden); @BeanTagAttribute @Override Boolean getReadOnly(); @Override void setReadOnly(Boolean readOnly); @Override Boolean getCanCopyOnReadOnly(); @Override void setCanCopyOnReadOnly(Boolean canCopyOnReadOnly); @BeanTagAttribute @Override Boolean getRequired(); @Override void setRequired(Boolean required); @BeanTagAttribute @Override boolean isRender(); @Override void setRender(boolean render); @BeanTagAttribute @Override boolean isRetrieveViaAjax(); @Override void setRetrieveViaAjax(boolean retrieveViaAjax); @BeanTagAttribute @Override int getColSpan(); @Override void setColSpan(int colSpan); @BeanTagAttribute @Override int getRowSpan(); @Override void setRowSpan(int rowSpan); @BeanTagAttribute @Override List<String> getWrapperCssClasses(); @Override void setWrapperCssClasses(List<String> wrapperCssClasses); @Override void addWrapperCssClass(String cssClass); String getWrapperCssClassesAsString(); @BeanTagAttribute @Override String getWrapperStyle(); @Override void setWrapperStyle(String wrapperStyle); @BeanTagAttribute @Override String getCellWidth(); @Override void setCellWidth(String cellWidth); @Override @BeanTagAttribute CssGridSizes getCssGridSizes(); @Override void setCssGridSizes(CssGridSizes cssGridSizes); @Override @BeanTagAttribute String getAlign(); @Override void setAlign(String align); @Override @BeanTagAttribute String getValign(); @Override void setValign(String valign); @Override @BeanTagAttribute String getWidth(); @Override void setWidth(String width); @Override @BeanTagAttribute String getStyle(); @Override void setStyle(String style); List<String> getLibraryCssClasses(); void setLibraryCssClasses(List<String> libraryCssClasses); @Override @BeanTagAttribute List<String> getCssClasses(); @Override void setCssClasses(List<String> cssClasses); @Override @BeanTagAttribute List<String> getAdditionalCssClasses(); @Override void setAdditionalCssClasses(List<String> additionalCssClasses); String getStyleClassesAsString(); @Override void addStyleClass(String styleClass); @Override void appendToStyle(String styleRules); @Override @BeanTagAttribute String getFinalizeMethodToCall(); void setFinalizeMethodToCall(String finalizeMethodToCall); @Override @BeanTagAttribute List<Object> getFinalizeMethodAdditionalArguments(); void setFinalizeMethodAdditionalArguments(List<Object> finalizeMethodAdditionalArguments); @Override @BeanTagAttribute MethodInvokerConfig getFinalizeMethodInvoker(); void setFinalizeMethodInvoker(MethodInvokerConfig finalizeMethodInvoker); @Override @BeanTagAttribute boolean isSelfRendered(); @Override void setSelfRendered(boolean selfRendered); @Override @BeanTagAttribute String getRenderedHtmlOutput(); @Override void setRenderedHtmlOutput(String renderedHtmlOutput); @Override @BeanTagAttribute boolean isDisableSessionPersistence(); @Override void setDisableSessionPersistence(boolean disableSessionPersistence); @Override @BeanTagAttribute boolean isForceSessionPersistence(); @Override void setForceSessionPersistence(boolean forceSessionPersistence); @Override @BeanTagAttribute(type = BeanTagAttribute.AttributeType.DIRECTORBYTYPE) ComponentSecurity getComponentSecurity(); @Override void setComponentSecurity(ComponentSecurity componentSecurity); @BeanTagAttribute Boolean isEditAuthz(); void setEditAuthz(Boolean editAuthz); @BeanTagAttribute Boolean isViewAuthz(); void setViewAuthz(Boolean viewAuthz); @Override @BeanTagAttribute List<ComponentModifier> getComponentModifiers(); @Override void setComponentModifiers(List<ComponentModifier> componentModifiers); @Override @BeanTagAttribute Map<String, Object> getContext(); @Override void setContext(Map<String, Object> context); @Override void pushObjectToContext(String objectName, Object object); @Override void pushAllToContext(Map<String, Object> objects); @Override @BeanTagAttribute List<PropertyReplacer> getPropertyReplacers(); @Override void setPropertyReplacers(List<PropertyReplacer> propertyReplacers); @Override @BeanTagAttribute int getOrder(); void setOrder(int order); @Override @BeanTagAttribute(type = BeanTagAttribute.AttributeType.DIRECTORBYTYPE) Tooltip getToolTip(); @Override void setToolTip(Tooltip toolTip); @Override String getEventHandlerScript(); @Override @BeanTagAttribute String getOnLoadScript(); void setOnLoadScript(String onLoadScript); @Override @BeanTagAttribute String getOnDocumentReadyScript(); void setOnDocumentReadyScript(String onDocumentReadyScript); @Override @BeanTagAttribute String getOnUnloadScript(); @Override void setOnUnloadScript(String onUnloadScript); @Override @BeanTagAttribute String getOnCloseScript(); @Override void setOnCloseScript(String onCloseScript); @Override @BeanTagAttribute String getOnBlurScript(); @Override void setOnBlurScript(String onBlurScript); @Override @BeanTagAttribute String getOnChangeScript(); @Override void setOnChangeScript(String onChangeScript); @Override @BeanTagAttribute String getOnClickScript(); @Override void setOnClickScript(String onClickScript); @Override @BeanTagAttribute String getOnDblClickScript(); @Override void setOnDblClickScript(String onDblClickScript); @Override @BeanTagAttribute String getOnFocusScript(); @Override void setOnFocusScript(String onFocusScript); @Override @BeanTagAttribute String getOnSubmitScript(); @Override void setOnSubmitScript(String onSubmitScript); @Override @BeanTagAttribute String getOnInputScript(); @Override void setOnInputScript(String onInputScript); @Override @BeanTagAttribute String getOnKeyPressScript(); @Override void setOnKeyPressScript(String onKeyPressScript); @Override @BeanTagAttribute String getOnKeyUpScript(); @Override void setOnKeyUpScript(String onKeyUpScript); @Override @BeanTagAttribute String getOnKeyDownScript(); @Override void setOnKeyDownScript(String onKeyDownScript); @Override @BeanTagAttribute String getOnMouseOverScript(); @Override void setOnMouseOverScript(String onMouseOverScript); @Override @BeanTagAttribute String getOnMouseOutScript(); @Override void setOnMouseOutScript(String onMouseOutScript); @Override @BeanTagAttribute String getOnMouseUpScript(); @Override void setOnMouseUpScript(String onMouseUpScript); @Override @BeanTagAttribute String getOnMouseDownScript(); @Override void setOnMouseDownScript(String onMouseDownScript); @Override @BeanTagAttribute String getOnMouseMoveScript(); @Override void setOnMouseMoveScript(String onMouseMoveScript); @Override @BeanTagAttribute Map<String, String> getTemplateOptions(); @Override void setTemplateOptions(Map<String, String> templateOptions); @Override @BeanTagAttribute String getTemplateOptionsJSString(); @Override void setTemplateOptionsJSString(String templateOptionsJSString); @BeanTagAttribute String getProgressiveRender(); void setProgressiveRender(String progressiveRender); @BeanTagAttribute String getConditionalRefresh(); void setConditionalRefresh(String conditionalRefresh); List<String> getProgressiveDisclosureControlNames(); String getProgressiveDisclosureConditionJs(); String getConditionalRefreshConditionJs(); List<String> getConditionalRefreshControlNames(); @BeanTagAttribute boolean isProgressiveRenderViaAJAX(); void setProgressiveRenderViaAJAX(boolean progressiveRenderViaAJAX); @BeanTagAttribute boolean isProgressiveRenderAndRefresh(); void setProgressiveRenderAndRefresh(boolean progressiveRenderAndRefresh); @Override @BeanTagAttribute List<String> getRefreshWhenChangedPropertyNames(); @Override void setRefreshWhenChangedPropertyNames(List<String> refreshWhenChangedPropertyNames); @Override @BeanTagAttribute(name = "additionalComponentsToRefresh", type = BeanTagAttribute.AttributeType.LISTVALUE) List<String> getAdditionalComponentsToRefresh(); @Override void setAdditionalComponentsToRefresh(List<String> additionalComponentsToRefresh); @Override String getAdditionalComponentsToRefreshJs(); @Override boolean isRefreshedByAction(); @Override void setRefreshedByAction(boolean refreshedByAction); @Override boolean isDisclosedByAction(); @Override void setDisclosedByAction(boolean disclosedByAction); @BeanTagAttribute int getRefreshTimer(); void setRefreshTimer(int refreshTimer); @Override @BeanTagAttribute boolean isResetDataOnRefresh(); @Override void setResetDataOnRefresh(boolean resetDataOnRefresh); @BeanTagAttribute String getMethodToCallOnRefresh(); void setMethodToCallOnRefresh(String methodToCallOnRefresh); @BeanTagAttribute List<String> getFieldsToSendOnRefresh(); void setFieldsToSendOnRefresh(List<String> fieldsToSendOnRefresh); @BeanTagAttribute boolean isSkipInTabOrder(); void setSkipInTabOrder(boolean skipInTabOrder); @Override @BeanTagAttribute Map<String, String> getDataAttributes(); @Override void setDataAttributes(Map<String, String> dataAttributes); @Override @BeanTagAttribute Map<String, String> getScriptDataAttributes(); @Override void setScriptDataAttributes(Map<String, String> scriptDataAttributes); @Override void addDataAttribute(String key, String value); @Override void addScriptDataAttribute(String key, String value); @Override String getSimpleDataAttributes(); @Override String getScriptDataAttributesJs(); @Override @BeanTagAttribute String getRole(); void setRole(String role); @Override @BeanTagAttribute Map<String, String> getAriaAttributes(); @Override void setAriaAttributes(Map<String, String> ariaAttributes); @Override void addAriaAttribute(String key, String value); @Override String getAriaAttributesAsString(); @BeanTagAttribute(name = "preContent", type = BeanTagAttribute.AttributeType.ANY) String getPreRenderContent(); @Override void setPreRenderContent(String preRenderContent); @Override @BeanTagAttribute(name = "postContent", type = BeanTagAttribute.AttributeType.ANY) String getPostRenderContent(); @Override void setPostRenderContent(String postRenderContent); @Override String getExcludeIf(); void setExcludeIf(String excludeIf); @Override String getExcludeUnless(); void setExcludeUnless(String excludeUnless); @Override ComponentBase clone(); @Override void completeValidation(ValidationTrace tracer); boolean isOmitFromFormPost(); void setOmitFromFormPost(boolean omitFromFormPost);  }
@Test public void testGetSimpleDataAttributes() throws Exception { assertNotNull(component.getSimpleDataAttributes()); String expected = " data-iconTemplateName=\"cool-icon-%s.png\" data-transitions=\"3\""; assertEquals("simple attributes did not match", expected, component.getSimpleDataAttributes()); }