public class SpaceUtil extends Object
Constructor and Description |
---|
SpaceUtil() |
Modifier and Type | Method and Description |
---|---|
static String |
formatAclDisplayName(String key) |
protected static boolean |
hasRole(org.springframework.security.core.Authentication authentication,
String role) |
static boolean |
isAdmin(org.springframework.security.core.Authentication authentication) |
protected static boolean |
isSnapshotProvider(ContentStore store) |
static void |
populateContentItem(String duradminBaseURL,
ContentItem contentItem,
String spaceId,
String contentId,
ContentStore store,
org.springframework.security.core.Authentication authentication) |
static Space |
populateSpace(Space space,
Space cloudSpace,
ContentStore contentStore,
org.springframework.security.core.Authentication authentication) |
static AclType |
resolveCallerAcl(String spaceId,
ContentStore store,
Map<String,AclType> acls,
org.springframework.security.core.Authentication authentication) |
static AclType |
resolveCallerAcl(String spaceId,
ContentStore store,
Map<String,AclType> acls,
org.springframework.security.core.Authentication authentication,
Boolean snapshotInProgress) |
static void |
sortAcls(List<Acl> acls) |
static void |
streamContent(ContentStore store,
javax.servlet.http.HttpServletResponse response,
String spaceId,
String contentId) |
static void |
streamToResponse(InputStream is,
javax.servlet.http.HttpServletResponse response,
String mimetype,
String contentLength) |
static List<Acl> |
toAclList(Map<String,AclType> spaceACLs) |
public static Space populateSpace(Space space, Space cloudSpace, ContentStore contentStore, org.springframework.security.core.Authentication authentication) throws ContentStoreException
ContentStoreException
public static void populateContentItem(String duradminBaseURL, ContentItem contentItem, String spaceId, String contentId, ContentStore store, org.springframework.security.core.Authentication authentication) throws ContentStoreException
ContentStoreException
public static void streamContent(ContentStore store, javax.servlet.http.HttpServletResponse response, String spaceId, String contentId) throws ContentStoreException, IOException
ContentStoreException
IOException
public static void streamToResponse(InputStream is, javax.servlet.http.HttpServletResponse response, String mimetype, String contentLength) throws ContentStoreException, IOException
ContentStoreException
IOException
public static AclType resolveCallerAcl(String spaceId, ContentStore store, Map<String,AclType> acls, org.springframework.security.core.Authentication authentication) throws ContentStoreException
ContentStoreException
public static AclType resolveCallerAcl(String spaceId, ContentStore store, Map<String,AclType> acls, org.springframework.security.core.Authentication authentication, Boolean snapshotInProgress) throws ContentStoreException
ContentStoreException
protected static boolean isSnapshotProvider(ContentStore store)
public static boolean isAdmin(org.springframework.security.core.Authentication authentication)
protected static boolean hasRole(org.springframework.security.core.Authentication authentication, String role)
Copyright © 2009–2014 DuraSpace. All rights reserved.