当前位置: 首页>>代码示例>>Java>>正文


Java Localizable类代码示例

本文整理汇总了Java中org.jvnet.localizer.Localizable的典型用法代码示例。如果您正苦于以下问题:Java Localizable类的具体用法?Java Localizable怎么用?Java Localizable使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


Localizable类属于org.jvnet.localizer包,在下文中一共展示了Localizable类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: verifyNumberOfItems

import org.jvnet.localizer.Localizable; //导入依赖的package包/类
/**
 * Verify number of items.
 */
@Test
public void verifyNumberOfItems() {
    AnnotationProvider provider = mock(AnnotationProvider.class);
    CheckStyleHealthDescriptor healthDescriptor = new CheckStyleHealthDescriptor(NullHealthDescriptor.NULL_HEALTH_DESCRIPTOR);

    Localizable description = healthDescriptor.createDescription(provider);
    assertEquals(WRONG_DESCRIPTION, Messages.Checkstyle_ResultAction_HealthReportNoItem(), description.toString());

    when(provider.getNumberOfAnnotations()).thenReturn(1);
    description = healthDescriptor.createDescription(provider);
    assertEquals(WRONG_DESCRIPTION, Messages.Checkstyle_ResultAction_HealthReportSingleItem(), description.toString());

    when(provider.getNumberOfAnnotations()).thenReturn(2);
    description = healthDescriptor.createDescription(provider);
    assertEquals(WRONG_DESCRIPTION, Messages.Checkstyle_ResultAction_HealthReportMultipleItem(2), description.toString());
}
 
开发者ID:davidparsson,项目名称:jslint-checkstyle-plugin,代码行数:20,代码来源:CheckStyleHealthDescriptorTest.java

示例2: createDescription

import org.jvnet.localizer.Localizable; //导入依赖的package包/类
/** {@inheritDoc} */
@Override
protected Localizable createDescription(final AnnotationProvider result) {
    if (result.getNumberOfAnnotations() == 0) {
        return Messages._Bandit_ResultAction_HealthReportNoItem();
    }
    else if (result.getNumberOfAnnotations() == 1) {
        return Messages._Bandit_ResultAction_HealthReportSingleItem();
    }
    else {
        return Messages._Bandit_ResultAction_HealthReportMultipleItem(result.getNumberOfAnnotations());
    }
}
 
开发者ID:mewz,项目名称:bandit-plugin-,代码行数:14,代码来源:BanditHealthDescriptor.java

示例3: createDescription

import org.jvnet.localizer.Localizable; //导入依赖的package包/类
@Override
protected Localizable createDescription(final AnnotationProvider result) {
    if (result.getNumberOfAnnotations() == 0) {
        return Messages._ResultAction_HealthReportNoItem();
    } else if (result.getNumberOfAnnotations() == 1) {
        return Messages._ResultAction_HealthReportSingleItem();
    } else {
        return Messages._ResultAction_HealthReportMultipleItem(result.getNumberOfAnnotations());
    }
}
 
开发者ID:jenkinsci,项目名称:dependency-check-plugin,代码行数:11,代码来源:DependencyCheckHealthDescriptor.java

示例4: getActionTitle

import org.jvnet.localizer.Localizable; //导入依赖的package包/类
public Localizable getActionTitle() {
    SupportPlugin supportPlugin = SupportPlugin.getInstance();
    if (supportPlugin != null) {
        SupportProvider supportProvider = supportPlugin.getSupportProvider();
        if (supportProvider != null) {
            return supportProvider.getActionTitle();
        }
    }
    return Messages._SupportAction_DefaultActionTitle();
}
 
开发者ID:jenkinsci,项目名称:support-core-plugin,代码行数:11,代码来源:SupportAction.java

示例5: getActionBlurb

import org.jvnet.localizer.Localizable; //导入依赖的package包/类
public Localizable getActionBlurb() {
    SupportPlugin supportPlugin = SupportPlugin.getInstance();
    if (supportPlugin != null) {
        SupportProvider supportProvider = supportPlugin.getSupportProvider();
        if (supportProvider != null) {
            return supportProvider.getActionBlurb();
        }
    }
    return Messages._SupportAction_DefaultActionBlurb();
}
 
开发者ID:jenkinsci,项目名称:support-core-plugin,代码行数:11,代码来源:SupportAction.java

示例6: createDescription

import org.jvnet.localizer.Localizable; //导入依赖的package包/类
@Override
protected Localizable createDescription(final AnnotationProvider result) {
    if (result.getNumberOfAnnotations() == 0) {
        return Messages._Checkstyle_ResultAction_HealthReportNoItem();
    }
    else if (result.getNumberOfAnnotations() == 1) {
        return Messages._Checkstyle_ResultAction_HealthReportSingleItem();
    }
    else {
        return Messages._Checkstyle_ResultAction_HealthReportMultipleItem(result.getNumberOfAnnotations());
    }
}
 
开发者ID:davidparsson,项目名称:jslint-checkstyle-plugin,代码行数:13,代码来源:CheckStyleHealthDescriptor.java

示例7: BranchWithMergeRequestCategory

import org.jvnet.localizer.Localizable; //导入依赖的package包/类
BranchWithMergeRequestCategory(@CheckForNull Localizable pronoun) {
    super("branchesWithMergeRequests", pronoun);
}
 
开发者ID:Argelbargel,项目名称:gitlab-branch-source-plugin,代码行数:4,代码来源:GitLabSCMHeadCategory.java

示例8: UpstreamFilterStrategy

import org.jvnet.localizer.Localizable; //导入依赖的package包/类
UpstreamFilterStrategy(boolean forGlobalSetting, Localizable displayName) {
    this.forGlobalSetting = forGlobalSetting;
    this.displayName = displayName;
}
 
开发者ID:jenkinsci,项目名称:run-selector-plugin,代码行数:5,代码来源:TriggeringRunSelector.java

示例9: BuildStatus

import org.jvnet.localizer.Localizable; //导入依赖的package包/类
BuildStatus(Localizable displayName) {
    this.displayName = displayName;
}
 
开发者ID:jenkinsci,项目名称:run-selector-plugin,代码行数:4,代码来源:StatusRunSelector.java

示例10: getBigImagePath

import org.jvnet.localizer.Localizable; //导入依赖的package包/类
public static String getBigImagePath(int score) {
  HealthReport healthReport = new HealthReport(score, (Localizable)null);
  return healthReport.getIconUrl("32x32");
}
 
开发者ID:jenkinsci,项目名称:flaky-test-handler-plugin,代码行数:5,代码来源:JUnitFlakyTestDataAction.java

示例11: getSmallImagePath

import org.jvnet.localizer.Localizable; //导入依赖的package包/类
public static String getSmallImagePath(int score) {
  HealthReport healthReport = new HealthReport(score, (Localizable)null);
  return healthReport.getIconUrl("16x16");
}
 
开发者ID:jenkinsci,项目名称:flaky-test-handler-plugin,代码行数:5,代码来源:JUnitFlakyTestDataAction.java

示例12: Status

import org.jvnet.localizer.Localizable; //导入依赖的package包/类
Status(String cssClass, Localizable message, boolean OK) {
  this.cssClass = cssClass;
  this.message = message;
  isOK = OK;
}
 
开发者ID:jenkinsci,项目名称:flaky-test-handler-plugin,代码行数:6,代码来源:FlakyCaseResult.java

示例13: info

import org.jvnet.localizer.Localizable; //导入依赖的package包/类
public void info(Localizable localizable) {
    info(String.valueOf(localizable));
}
 
开发者ID:jenkinsci,项目名称:xldeploy-plugin,代码行数:4,代码来源:JenkinsDeploymentListener.java

示例14: error

import org.jvnet.localizer.Localizable; //导入依赖的package包/类
public void error(Localizable localizable) {
    error(String.valueOf(localizable));
}
 
开发者ID:jenkinsci,项目名称:xldeploy-plugin,代码行数:4,代码来源:JenkinsDeploymentListener.java

示例15: _VersionOne_Notifier

import org.jvnet.localizer.Localizable; //导入依赖的package包/类
public static Localizable _VersionOne_Notifier() {
    return new Localizable(holder, "VersionOne.Notifier");
}
 
开发者ID:versionone,项目名称:VersionOne.Integration.Jenkins,代码行数:4,代码来源:MessagesRes.java


注:本文中的org.jvnet.localizer.Localizable类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。