ReportOutputType.javaprojectforge-business/src/main/java/org/projectforge/business/fibu/kost/reporting/ReportOutputType.java contenant du code Java pour la couche Comptabilité financière.Package : org.projectforge.business.fibu.kost.reporting
Énumérations : ReportOutputType
Méthodes (3) : getOrdinal, getType, getKey
Champs (1) : key
Importations : 1 package
package org.projectforge.business.fibu.kost.reporting;
import org.apache.commons.lang3.StringUtils;
public enum ReportOutputType
{
PDF("pdf");
private String key;
/**
* @see #ordinal()
*/
public int getOrdinal()
{
return ordinal();
}
/**
* @param s Clé ou valeur toString du type, p. ex. "pdf" ou "PDF".
* @return ReportOutputType correspondant.
* @throws UnsupportedOperationException si aucun type ne correspond.
*/
public static ReportOutputType getType(String s)
{
if (StringUtils.isEmpty(s)) {
return null;
}
for (ReportOutputType type : ReportOutputType.values()) {
if (s.equals(type.toString()) || s.equals(type.getKey())) {
return type;
}
}
throw new UnsupportedOperationException("Type de rapport inconnu : '" + s + "'");
}
/**
* La clé sera utilisée p. ex. pour l'i18n.
*
* @return
*/
public String getKey()
{
return key;
}
ReportOutputType(String key)
{
this.key = key;
}
}
868d6abb7 2025 -> 2026 63081666f En-têtes des fichiers source : 2024 -> 2025. b6092df09 Copyright 2023 -> 2024 ab45d51fa Copyright 2001-2022 -> 2001-2023. 5f7ef41b8 Copyright 2021 -> 2022