sirius.biz.jobs.system.SystemJobDescription Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of sirius-biz Show documentation
Show all versions of sirius-biz Show documentation
Provides a framework for building web based business applications
/*
* Made with all the love in the world
* by scireum in Remshalden, Germany
*
* Copyright by scireum GmbH
* http://www.scireum.de - [email protected]
*/
package sirius.biz.jobs.system;
import com.google.common.collect.Lists;
import sirius.biz.jobs.JobDescription;
import sirius.kernel.nls.NLS;
import sirius.web.security.Permissions;
import javax.annotation.Nonnull;
import javax.annotation.Nullable;
import java.util.List;
import java.util.Set;
/**
* Created by aha on 22.07.16.
*/
public abstract class SystemJobDescription extends JobDescription {
protected final Set requiredPermissions = Permissions.computePermissionsFromAnnotations(getClass());
@Nonnull
@Override
public String getTitle() {
return NLS.get("Job." + getName());
}
@Nullable
@Override
public String getDescription() {
return NLS.getIfExists("Job." + getName() + ".help", NLS.getCurrentLang()).orElse(null);
}
@Nonnull
@Override
public String getFactory() {
return SystemJobsFactory.SYSTEM;
}
@Override
public List getPermissions() {
return Lists.newArrayList(requiredPermissions);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy