當前位置: 首頁>>代碼示例>>Java>>正文


Java ComponentBase類代碼示例

本文整理匯總了Java中org.kuali.rice.krad.uif.component.ComponentBase的典型用法代碼示例。如果您正苦於以下問題:Java ComponentBase類的具體用法?Java ComponentBase怎麽用?Java ComponentBase使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


ComponentBase類屬於org.kuali.rice.krad.uif.component包,在下文中一共展示了ComponentBase類的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: testCopyUsingCloningWithSimpleCollectionGroupSucceeds

import org.kuali.rice.krad.uif.component.ComponentBase; //導入依賴的package包/類
/**
 * test {@link ComponentUtils#copyUsingCloning} using a CollectionGroup object
 */
@Test
public void testCopyUsingCloningWithSimpleCollectionGroupSucceeds() {
    CollectionGroup collectionGroupOriginal = initializeCollectionGroup();
    CollectionGroup collectionGroupCopy = CopyUtils.copy(collectionGroupOriginal);

    assertTrue(ComponentCopyPropertiesMatch(collectionGroupOriginal, collectionGroupCopy));

    for (int i = 0; i < collectionGroupOriginal.getAddLineItems().size(); i++) {
        assertTrue(ComponentCopyPropertiesMatch(
                CopyUtils.unwrap((ComponentBase) collectionGroupOriginal.getAddLineItems().get(i)),
                CopyUtils.unwrap((ComponentBase) collectionGroupCopy.getAddLineItems().get(i))));
    }

    for (int i = 0; i < collectionGroupOriginal.getAddLineActions().size(); i++) {
        assertTrue(ComponentCopyPropertiesMatch(
                CopyUtils.unwrap((Component) collectionGroupOriginal.getAddLineActions().get(i)),
                CopyUtils.unwrap((Component) collectionGroupCopy.getAddLineActions().get(i))));
    }
}
 
開發者ID:kuali,項目名稱:kc-rice,代碼行數:23,代碼來源:ComponentUtilsTest.java

示例2: addCellStyling

import org.kuali.rice.krad.uif.component.ComponentBase; //導入依賴的package包/類
/**
 * Add the css style to the cellCssClasses by column index, later used by the aoColumnDefs
 *
 * @param manager the tableLayoutManager that contains the original fields
 */
private void addCellStyling(TableLayoutManager manager) {
    if (!CollectionUtils.isEmpty(manager.getAllRowFields())) {
        for (int index = 0; index < manager.getNumberOfColumns(); index++) {
            String cellStyleClasses = ((ComponentBase) manager.getAllRowFields().get(index))
                    .getWrapperCssClassesAsString();
            if (StringUtils.isNotBlank(cellStyleClasses)) {
                cellCssClasses.add(cellStyleClasses);
            }
        }
    }
}
 
開發者ID:kuali,項目名稱:kc-rice,代碼行數:17,代碼來源:RichTable.java

示例3: addCellStyling

import org.kuali.rice.krad.uif.component.ComponentBase; //導入依賴的package包/類
/**
 * Add the css style to the cellCssClasses by column index, later used by the aoColumnDefs
 *
 * @param manager the tableLayoutManager that contains the original fields
 */
private void addCellStyling(TableLayoutManager manager) {
    if (manager.getAllRowFields() != null) {
        for (int index = 0; index < manager.getNumberOfColumns(); index++) {
            String cellStyleClasses = ((ComponentBase) manager.getAllRowFields().get(index))
                    .getCellStyleClassesAsString();
            cellCssClasses.add(cellStyleClasses);
        }
    }
}
 
開發者ID:aapotts,項目名稱:kuali_rice,代碼行數:15,代碼來源:RichTable.java

示例4: ComponentCopyPropertiesMatch

import org.kuali.rice.krad.uif.component.ComponentBase; //導入依賴的package包/類
private boolean ComponentCopyPropertiesMatch(ComponentBase originalComponent, ComponentBase copiedComponent) {
    boolean result = true;

    List<String> missingComponentsToRefresh = originalComponent.getAdditionalComponentsToRefresh();
    missingComponentsToRefresh.removeAll(copiedComponent.getAdditionalComponentsToRefresh());
    if (!missingComponentsToRefresh.isEmpty()) result = false;

    List<String> missingAdditionalCssClasses = originalComponent.getAdditionalCssClasses();
    missingAdditionalCssClasses.removeAll(copiedComponent.getAdditionalCssClasses());
    if (!missingAdditionalCssClasses.isEmpty()) result = false;

    if (!originalComponent.getAlign().equals(copiedComponent.getAlign())) result = false;

    List<String> missingCellCssClasses = originalComponent.getCellCssClasses();
    missingCellCssClasses.removeAll(copiedComponent.getCellCssClasses());
    if (!missingCellCssClasses.isEmpty()) result = false;

    if (!originalComponent.getCellStyle().equals(copiedComponent.getCellStyle())) result = false;
    if (!originalComponent.getCellWidth().equals(copiedComponent.getCellWidth())) result = false;
    if (originalComponent.getColSpan() != copiedComponent.getColSpan()) result = false;
    if (!originalComponent.getConditionalRefresh().equals(copiedComponent.getConditionalRefresh())) result = false;

    List<String> missingCssClasses = originalComponent.getCssClasses();
    missingCssClasses.removeAll(copiedComponent.getCssClasses());
    if (!missingCssClasses.isEmpty()) result = false;

    Set dataAttributes = new HashSet(originalComponent.getDataAttributes().values());
    dataAttributes.removeAll(copiedComponent.getDataAttributes().values());
    if (!dataAttributes.isEmpty()) result = false;

    if (!originalComponent.getFinalizeMethodToCall().equals(copiedComponent.getFinalizeMethodToCall())) result = false;
    if (!originalComponent.getMethodToCallOnRefresh().equals(copiedComponent.getMethodToCallOnRefresh())) result = false;
    if (!originalComponent.getOnBlurScript().equals(copiedComponent.getOnBlurScript())) result = false;
    if (!originalComponent.getOnChangeScript().equals(copiedComponent.getOnChangeScript())) result = false;
    if (!originalComponent.getOnClickScript().equals(copiedComponent.getOnClickScript())) result = false;
    if (!originalComponent.getOnCloseScript().equals(copiedComponent.getOnCloseScript())) result = false;
    if (!originalComponent.getOnDblClickScript().equals(copiedComponent.getOnDblClickScript())) result = false;
    if (!originalComponent.getOnDocumentReadyScript().equals(copiedComponent.getOnDocumentReadyScript())) result = false;
    if (!originalComponent.getOnFocusScript().equals(copiedComponent.getOnFocusScript())) result = false;
    if (!originalComponent.getOnKeyDownScript().equals(copiedComponent.getOnKeyDownScript())) result = false;
    if (!originalComponent.getOnKeyPressScript().equals(copiedComponent.getOnKeyPressScript())) result = false;
    if (!originalComponent.getOnKeyUpScript().equals(copiedComponent.getOnKeyUpScript())) result = false;
    if (!originalComponent.getOnLoadScript().equals(copiedComponent.getOnLoadScript())) result = false;
    if (!originalComponent.getOnMouseDownScript().equals(copiedComponent.getOnMouseDownScript())) result = false;
    if (!originalComponent.getOnMouseMoveScript().equals(copiedComponent.getOnMouseMoveScript())) result = false;
    if (!originalComponent.getOnMouseOutScript().equals(copiedComponent.getOnMouseOutScript())) result = false;
    if (!originalComponent.getOnMouseOverScript().equals(copiedComponent.getOnMouseOverScript())) result = false;
    if (!originalComponent.getOnMouseUpScript().equals(copiedComponent.getOnMouseUpScript())) result = false;
    if (!originalComponent.getOnSubmitScript().equals(copiedComponent.getOnSubmitScript())) result = false;
    if (!originalComponent.getOnUnloadScript().equals(copiedComponent.getOnUnloadScript())) result = false;
    if (originalComponent.getOrder() != copiedComponent.getOrder()) result = false;
    if (!originalComponent.getPostRenderContent().equals(copiedComponent.getPostRenderContent())) result = false;
    if (!originalComponent.getPreRenderContent().equals(copiedComponent.getPreRenderContent())) result = false;
    if (!originalComponent.getProgressiveRender().equals(copiedComponent.getProgressiveRender())) result = false;
    if (originalComponent.getRequired() != copiedComponent.getRequired()) result = false;
    if (originalComponent.getRefreshTimer() != copiedComponent.getRefreshTimer()) result = false;

    List<String> missingRefreshWhenChangedPropertyNames = originalComponent.getRefreshWhenChangedPropertyNames();
    missingRefreshWhenChangedPropertyNames.removeAll(copiedComponent.getRefreshWhenChangedPropertyNames());
    if (!missingRefreshWhenChangedPropertyNames.isEmpty()) result = false;

    if (!originalComponent.getRenderedHtmlOutput().equals(copiedComponent.getRenderedHtmlOutput())) result = false;
    if (originalComponent.getRowSpan() != copiedComponent.getRowSpan()) result = false;
    if (!originalComponent.getStyle().equals(copiedComponent.getStyle())) result = false;
    if (!originalComponent.getTemplate().equals(copiedComponent.getTemplate())) result = false;
    if (!originalComponent.getTemplateName().equals(copiedComponent.getTemplateName())) result = false;

    Set templateOptions = new HashSet(originalComponent.getTemplateOptions().values());
    templateOptions.removeAll(copiedComponent.getTemplateOptions().values());
    if (!templateOptions.isEmpty()) result = false;

    if (!originalComponent.getTemplateOptionsJSString().equals(copiedComponent.getTemplateOptionsJSString())) result = false;
    if (!originalComponent.getTitle().equals(copiedComponent.getTitle())) result = false;
    if (!originalComponent.getValign().equals(copiedComponent.getValign())) result = false;
    if (!originalComponent.getWidth().equals(copiedComponent.getWidth())) result = false;

    return result;
}
 
開發者ID:aapotts,項目名稱:kuali_rice,代碼行數:79,代碼來源:ComponentUtilsTest.java


注:本文中的org.kuali.rice.krad.uif.component.ComponentBase類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。