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


Java Description.value方法代碼示例

本文整理匯總了Java中org.datacleaner.api.Description.value方法的典型用法代碼示例。如果您正苦於以下問題:Java Description.value方法的具體用法?Java Description.value怎麽用?Java Description.value使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在org.datacleaner.api.Description的用法示例。


在下文中一共展示了Description.value方法的8個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: getDisplayName

import org.datacleaner.api.Description; //導入方法依賴的package包/類
@Override
public String getDisplayName() {
    // this is the 'descriptor' name, e.g. will be used for CSS styling
    final Description desc = ReflectionUtils.getAnnotation(_componentClass, Description.class);
    if (desc == null || StringUtils.isNullOrEmpty(desc.value())) {
        return _componentClass.getSimpleName();
    }
    return desc.value();
}
 
開發者ID:datacleaner,項目名稱:DataCleaner,代碼行數:10,代碼來源:PlaceholderComponentJob.java

示例2: getDescription

import org.datacleaner.api.Description; //導入方法依賴的package包/類
@Override
public final String getDescription() {
    final Description description = getAnnotation(Description.class);
    if (description == null) {
        return null;
    }
    return description.value();
}
 
開發者ID:datacleaner,項目名稱:DataCleaner,代碼行數:9,代碼來源:SimpleComponentDescriptor.java

示例3: getDescription

import org.datacleaner.api.Description; //導入方法依賴的package包/類
@Override
public String getDescription() {
    final Description desc = getAnnotation(Description.class);
    if (desc == null) {
        return null;
    }
    return desc.value();
}
 
開發者ID:datacleaner,項目名稱:DataCleaner,代碼行數:9,代碼來源:ConfiguredPropertyDescriptorImpl.java

示例4: getDescription

import org.datacleaner.api.Description; //導入方法依賴的package包/類
@Override
public final String getDescription() {
    final Description desc = getAnnotation(Description.class);
    if (desc == null) {
        return null;
    }
    return desc.value();
}
 
開發者ID:datacleaner,項目名稱:DataCleaner,代碼行數:9,代碼來源:AbstractMetricDescriptor.java

示例5: getDescription

import org.datacleaner.api.Description; //導入方法依賴的package包/類
public String getDescription() {
    final Description annotation = ReflectionUtils.getAnnotation(_outcome, Description.class);
    if (annotation == null) {
        return "";
    }

    final String description = annotation.value();
    return DocumentationUtils.createHtmlParagraphs(description);
}
 
開發者ID:datacleaner,項目名稱:DataCleaner,代碼行數:10,代碼來源:FilterOutcomeDocumentationWrapper.java

示例6: render

import org.datacleaner.api.Description; //導入方法依賴的package包/類
@Override
public HtmlFragment render(final AnnotatedRowsResult result) {
    final SimpleHtmlFragment htmlFragment = new SimpleHtmlFragment();

    final InputColumn<?>[] highlightedColumns = result.getHighlightedColumns();
    final int[] highlightedIndexes = new int[highlightedColumns.length];
    for (int i = 0; i < highlightedColumns.length; i++) {
        highlightedIndexes[i] = result.getColumnIndex(highlightedColumns[i]);
    }

    final TableModel tableModel = result.toTableModel(MAX_ROWS);

    final Description description = ReflectionUtils.getAnnotation(result.getClass(), Description.class);
    final String descriptionText;
    if (description != null) {
        descriptionText = description.value();
    } else {
        descriptionText = "Records";
    }
    final int rowCount = result.getAnnotatedRowCount();
    htmlFragment.addBodyElement(new SectionHeaderBodyElement(descriptionText + " (" + rowCount + ")"));

    if (rowCount == 0) {
        htmlFragment.addBodyElement("<p>No records to display.</p>");
    } else {
        htmlFragment.addBodyElement(new TableBodyElement(tableModel, "annotatedRowsTable", highlightedIndexes));
    }

    return htmlFragment;
}
 
開發者ID:datacleaner,項目名稱:DataCleaner,代碼行數:31,代碼來源:AnnotatedRowsHtmlRenderer.java

示例7: render

import org.datacleaner.api.Description; //導入方法依賴的package包/類
@Override
public HtmlFragment render(final ListResult<?> result) {
    final SimpleHtmlFragment htmlFragment = new SimpleHtmlFragment();

    final List<?> values = result.getValues();

    final int rowCount = values.size();
    final TableModel tableModel = new DefaultTableModel(rowCount, 1);
    for (int i = 0; i < rowCount; i++) {
        tableModel.setValueAt(values.get(i), i, 0);

    }

    final Description description = ReflectionUtils.getAnnotation(result.getClass(), Description.class);
    final String descriptionText;
    if (description != null) {
        descriptionText = description.value();
    } else {
        descriptionText = "Values";
    }

    htmlFragment.addBodyElement(new SectionHeaderBodyElement(descriptionText + " (" + rowCount + ")"));

    if (rowCount == 0) {
        htmlFragment.addBodyElement("<p>No records to display.</p>");
    } else {
        htmlFragment.addBodyElement(new TableBodyElement(tableModel, "annotatedRowsTable", new int[0]));
    }

    return htmlFragment;
}
 
開發者ID:datacleaner,項目名稱:DataCleaner,代碼行數:32,代碼來源:ListResultHtmlRenderer.java

示例8: AnnotatedRowResultPanel

import org.datacleaner.api.Description; //導入方法依賴的package包/類
public AnnotatedRowResultPanel(final AnnotatedRowsResult result, final UserPreferences userPreferences,
        final DatastoreCatalog datastoreCatalog) {
    super();
    _result = result;
    _userPreferences = userPreferences;
    _datastoreCatalog = datastoreCatalog;

    setLayout(new VerticalLayout(4));

    _table = new DCTable();
    _table.setColumnControlVisible(false);

    final InputColumn<?>[] highlightedColumns = result.getHighlightedColumns();
    final List<InputColumn<?>> inputColumns = result.getInputColumns();

    final JToolBar buttonToolBar = WidgetFactory.createToolBar();
    buttonToolBar.setBorder(new EmptyBorder(0, 4, 0, 4));

    final Description description = ReflectionUtils.getAnnotation(result.getClass(), Description.class);
    final String descriptionText;
    if (description != null) {
        descriptionText = description.value();
    } else {
        descriptionText = "Records";
    }

    final int annotatedRowCount = result.getAnnotation().getRowCount();
    final DCLabel label = DCLabel.dark(descriptionText + " (" + result.getAnnotatedRowCount() + ")");
    label.setFont(WidgetUtils.FONT_HEADER1);
    buttonToolBar.add(label);
    buttonToolBar.add(WidgetFactory.createToolBarSeparator());

    if (highlightedColumns.length == 1 && inputColumns.size() > 1) {
        final DCComboBox<String> comboBox = new DCComboBox<>(VIEWS);
        comboBox.addListener(item -> {
            if (item == VIEWS[0]) {
                applyDetailedView();
            } else {
                applyDistinctValuesView();
            }
        });
        comboBox.setSelectedItem(VIEWS[0]);
        comboBox.notifyListeners();

        buttonToolBar.add(comboBox);
    } else {
        applyDetailedView();
    }

    final PopupButton saveToFileButton = createSaveToFileButton(inputColumns);
    buttonToolBar.add(saveToFileButton);

    add(buttonToolBar);

    if (annotatedRowCount == 0) {
        final DCLabel noRecordsLabel = DCLabel.dark("No records to display.");
        noRecordsLabel.setBorder(new EmptyBorder(0, 4, 0, 0));
        add(noRecordsLabel);
    } else {
        final DCPanel tablePanel = _table.toPanel();
        add(WidgetUtils.decorateWithShadow(tablePanel));
    }
}
 
開發者ID:datacleaner,項目名稱:DataCleaner,代碼行數:64,代碼來源:AnnotatedRowsResultSwingRenderer.java


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