com.memority.citadel.shared.api.im.BuiltinActivationMode Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of citadel-api Show documentation
Show all versions of citadel-api Show documentation
This artifact provides the API classes that are necessary to implement general configuration Rules on the Memority IM platform.
/*
* Copyright (c) 2016-2023 Memority. All Rights Reserved.
*
* This file is part of Memority Citadel API , a Memority project.
*
* This file is released under the Memority Public Artifacts End-User License Agreement,
* see
* Unauthorized copying of this file, via any medium is strictly prohibited.
*/
package com.memority.citadel.shared.api.im;
import java.util.Set;
import java.util.stream.Collectors;
import java.util.stream.Stream;
public enum BuiltinActivationMode {
AUTO(Value.AUTO), ADMIN(Value.ADMIN);
private String value;
BuiltinActivationMode(String value) {
this.value = value;
}
public String getValue() {
return value;
}
public interface Value {
String AUTO = "AUTO";
String ADMIN = "ADMIN";
}
public static Set getEffectiveAvailableModes(Set availableModes) {
return Stream.concat(
availableModes.stream(),
Stream.of(BuiltinActivationMode.values()).map(BuiltinActivationMode::getValue)
)
.collect(Collectors.toSet());
}
}