public class ExportUtils extends Object
Constructor and Description |
---|
ExportUtils() |
Modifier and Type | Method and Description |
---|---|
static ResourceServerRepresentation |
exportAuthorizationSettings(KeycloakSession session,
ClientModel client) |
static ClientRepresentation |
exportClient(KeycloakSession session,
ClientModel client)
Full export of application including claims and secret
|
static org.keycloak.common.util.MultivaluedHashMap<String,ComponentExportRepresentation> |
exportComponents(RealmModel realm,
String parentId) |
static CredentialRepresentation |
exportCredential(CredentialModel userCred) |
static UserRepresentation |
exportFederatedUser(KeycloakSession session,
RealmModel realm,
String id,
ExportOptions options)
Full export of user data stored in federated storage (including role mappings and credentials)
|
static void |
exportFederatedUsersToStream(KeycloakSession session,
RealmModel realm,
List<String> usersToExport,
com.fasterxml.jackson.databind.ObjectMapper mapper,
OutputStream os) |
static void |
exportFederatedUsersToStream(KeycloakSession session,
RealmModel realm,
List<String> usersToExport,
com.fasterxml.jackson.databind.ObjectMapper mapper,
OutputStream os,
ExportOptions options) |
static RealmRepresentation |
exportRealm(KeycloakSession session,
RealmModel realm,
boolean includeUsers,
boolean internal) |
static RealmRepresentation |
exportRealm(KeycloakSession session,
RealmModel realm,
ExportOptions options,
boolean internal) |
static RoleRepresentation |
exportRole(RoleModel role)
Full export of role including composite roles
|
static List<RoleRepresentation> |
exportRoles(Collection<RoleModel> roles) |
static FederatedIdentityRepresentation |
exportSocialLink(FederatedIdentityModel socialLink) |
static UserRepresentation |
exportUser(KeycloakSession session,
RealmModel realm,
UserModel user,
ExportOptions options)
Full export of user (including role mappings and credentials)
|
static void |
exportUsersToStream(KeycloakSession session,
RealmModel realm,
List<UserModel> usersToExport,
com.fasterxml.jackson.databind.ObjectMapper mapper,
OutputStream os) |
static void |
exportUsersToStream(KeycloakSession session,
RealmModel realm,
List<UserModel> usersToExport,
com.fasterxml.jackson.databind.ObjectMapper mapper,
OutputStream os,
ExportOptions options) |
static List<String> |
getRoleNames(Collection<RoleModel> roles) |
public static RealmRepresentation exportRealm(KeycloakSession session, RealmModel realm, boolean includeUsers, boolean internal)
public static RealmRepresentation exportRealm(KeycloakSession session, RealmModel realm, ExportOptions options, boolean internal)
public static org.keycloak.common.util.MultivaluedHashMap<String,ComponentExportRepresentation> exportComponents(RealmModel realm, String parentId)
public static ClientRepresentation exportClient(KeycloakSession session, ClientModel client)
client
- public static ResourceServerRepresentation exportAuthorizationSettings(KeycloakSession session, ClientModel client)
public static List<RoleRepresentation> exportRoles(Collection<RoleModel> roles)
public static List<String> getRoleNames(Collection<RoleModel> roles)
public static RoleRepresentation exportRole(RoleModel role)
role
- public static UserRepresentation exportUser(KeycloakSession session, RealmModel realm, UserModel user, ExportOptions options)
user
- public static FederatedIdentityRepresentation exportSocialLink(FederatedIdentityModel socialLink)
public static CredentialRepresentation exportCredential(CredentialModel userCred)
public static void exportUsersToStream(KeycloakSession session, RealmModel realm, List<UserModel> usersToExport, com.fasterxml.jackson.databind.ObjectMapper mapper, OutputStream os) throws IOException
IOException
public static void exportUsersToStream(KeycloakSession session, RealmModel realm, List<UserModel> usersToExport, com.fasterxml.jackson.databind.ObjectMapper mapper, OutputStream os, ExportOptions options) throws IOException
IOException
public static void exportFederatedUsersToStream(KeycloakSession session, RealmModel realm, List<String> usersToExport, com.fasterxml.jackson.databind.ObjectMapper mapper, OutputStream os) throws IOException
IOException
public static void exportFederatedUsersToStream(KeycloakSession session, RealmModel realm, List<String> usersToExport, com.fasterxml.jackson.databind.ObjectMapper mapper, OutputStream os, ExportOptions options) throws IOException
IOException
public static UserRepresentation exportFederatedUser(KeycloakSession session, RealmModel realm, String id, ExportOptions options)
id
- Copyright © 2019 JBoss by Red Hat. All rights reserved.