public class ExportUtils extends Object
Modifier and Type | Field and Description |
---|---|
static String |
PROP_BACKUP_ATTACHMENTS |
static String |
PROP_BUILD_NUMBER
build number of the earliest confluence version that this export can be imported by
|
static String |
PROP_CREATED_BY_BUILD_NUMBER
build number of the version of confluence that was used to generate export
|
static String |
PROP_DEFAULT_USERS_GROUP
Default users group for this instance, used to remap group permissions on import.
|
static String |
PROP_EXPORT_TYPE |
static String |
PROP_EXPORTED_SPACEKEY
Indicates a specific space key which has been exported.
|
static String |
PROP_PLUGIN_CREATED_BY_VERSION
Plugin version used to export (Mostly for ActiveObjects data)
|
static String |
PROP_PLUGIN_EARLIEST_VERSION
Earliest plugin version compatible with export
|
static String |
PROP_PLUGINS_EXPORTING_DATA |
static String |
PROP_TIMEZONE_ID |
Constructor and Description |
---|
ExportUtils() |
Modifier and Type | Method and Description |
---|---|
static String |
getTitleAsFilename(ContentEntityObject ceo)
Utility method to return a version of the content entity's title that's suitable to be used as a filename in an export.
|
static String |
getTitleAsFilename(SearchResult searchResult) |
protected static String |
getTitleAsFilename(String title,
String id) |
static boolean |
isSafeTitleForFilesystem(String title)
Ensure the title is safe to be written to the file system.
|
public static final String PROP_BUILD_NUMBER
public static final String PROP_TIMEZONE_ID
public static final String PROP_EXPORT_TYPE
public static final String PROP_BACKUP_ATTACHMENTS
public static final String PROP_EXPORTED_SPACEKEY
public static final String PROP_CREATED_BY_BUILD_NUMBER
public static final String PROP_DEFAULT_USERS_GROUP
public static final String PROP_PLUGIN_CREATED_BY_VERSION
public static final String PROP_PLUGIN_EARLIEST_VERSION
public static final String PROP_PLUGINS_EXPORTING_DATA
public static String getTitleAsFilename(ContentEntityObject ceo)
Utility method to return a version of the content entity's title that's suitable to be used as a filename in an export. Falls back to using the content entity's ID if the title contains unsuitable characters.
This method is used to centralise the code since symmetry is required in the creation of the files during export and the creation of the links to these files in the exported content.
ceo
- the ContentEntityObject to retrieve a suitable filename for.public static String getTitleAsFilename(SearchResult searchResult)
public static boolean isSafeTitleForFilesystem(String title)
title
- The title to checkCopyright © 2003–2017 Atlassian. All rights reserved.