public class LicenseUtils
extends java.lang.Object
| Constructor and Description |
|---|
LicenseUtils() |
| Modifier and Type | Method and Description |
|---|---|
static java.lang.String |
getLicenseText(java.util.Locale locale,
Collection collection,
Item item,
EPerson eperson)
Utility method if no additional arguments are to be supplied to the
license template.
|
static java.lang.String |
getLicenseText(java.util.Locale locale,
Collection collection,
Item item,
EPerson eperson,
java.util.Map<java.lang.String,java.lang.Object> additionalInfo)
Return the text of the license that the user has granted/must grant
before for submit the item.
|
static void |
grantLicense(Context context,
Item item,
java.lang.String licenseText)
Store a copy of the license a user granted in the item.
|
public static java.lang.String getLicenseText(java.util.Locale locale,
Collection collection,
Item item,
EPerson eperson,
java.util.Map<java.lang.String,java.lang.Object> additionalInfo)
locale - collection - item - eperson - additionalInfo - LicenseArgumentFormatterpublic static java.lang.String getLicenseText(java.util.Locale locale,
Collection collection,
Item item,
EPerson eperson)
null for the additionalInfo argument)locale - collection - item - eperson - public static void grantLicense(Context context, Item item, java.lang.String licenseText) throws java.sql.SQLException, java.io.IOException, AuthorizeException
context - the dspace contextitem - the item object of the licenselicenseText - the license the user grantedjava.sql.SQLExceptionjava.io.IOExceptionAuthorizeExceptionCopyright © 2018 DuraSpace. All Rights Reserved.