Class RealmLocalizationResource
- java.lang.Object
-
- org.keycloak.services.resources.admin.RealmLocalizationResource
-
public class RealmLocalizationResource extends Object
-
-
Field Summary
Fields Modifier and Type Field Description protected KeycloakSession
session
-
Constructor Summary
Constructors Constructor Description RealmLocalizationResource(KeycloakSession session, AdminPermissionEvaluator auth)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
createOrUpdateRealmLocalizationTexts(String locale, Map<String,String> localizationTexts)
void
createOrUpdateRealmLocalizationTextsFromFile(String locale)
Import localization from uploaded JSON filevoid
deleteRealmLocalizationText(String locale, String key)
void
deleteRealmLocalizationTexts(String locale)
Stream<String>
getRealmLocalizationLocales()
String
getRealmLocalizationText(String locale, String key)
Map<String,String>
getRealmLocalizationTexts(String locale, Boolean useFallback)
void
saveRealmLocalizationText(String locale, String key, String text)
-
-
-
Field Detail
-
session
protected final KeycloakSession session
-
-
Constructor Detail
-
RealmLocalizationResource
public RealmLocalizationResource(KeycloakSession session, AdminPermissionEvaluator auth)
-
-
Method Detail
-
saveRealmLocalizationText
@Path("{locale}/{key}") @PUT @Consumes("text/plain") public void saveRealmLocalizationText(@PathParam("locale") String locale, @PathParam("key") String key, String text)
-
createOrUpdateRealmLocalizationTextsFromFile
@POST @Path("{locale}") @Consumes("multipart/form-data") public void createOrUpdateRealmLocalizationTextsFromFile(@PathParam("locale") String locale)
Import localization from uploaded JSON file
-
createOrUpdateRealmLocalizationTexts
@POST @Path("{locale}") @Consumes("application/json") public void createOrUpdateRealmLocalizationTexts(@PathParam("locale") String locale, Map<String,String> localizationTexts)
-
deleteRealmLocalizationTexts
@Path("{locale}") @DELETE public void deleteRealmLocalizationTexts(@PathParam("locale") String locale)
-
deleteRealmLocalizationText
@Path("{locale}/{key}") @DELETE public void deleteRealmLocalizationText(@PathParam("locale") String locale, @PathParam("key") String key)
-
getRealmLocalizationLocales
@GET @Produces("application/json") public Stream<String> getRealmLocalizationLocales()
-
getRealmLocalizationTexts
@Path("{locale}") @GET @Produces("application/json") public Map<String,String> getRealmLocalizationTexts(@PathParam("locale") String locale, @QueryParam("useRealmDefaultLocaleFallback") Boolean useFallback)
-
-