Navigation
API > API/Plugins > API/Plugins/ContentBrowserAliasDataSource
Inheritance Hierarchy
- UObjectBase
- UObjectBaseUtility
- UObject
- UContentBrowserDataSource
- UContentBrowserAliasDataSource
References
| Module | ContentBrowserAliasDataSource |
| Header | /Engine/Plugins/Editor/ContentBrowser/ContentBrowserAliasDataSoure/Source/ContentBrowserAliasDataSource/Public/ContentBrowserAliasDataSource.h |
| Include | #include "ContentBrowserAliasDataSource.h" |
Syntax
UCLASS&40;&41;
class UContentBrowserAliasDataSource : public UContentBrowserDataSource
Remarks
A companion to the ContentBrowserAssetDataSource which can display assets in folders other than their actual folder. Aliases mimic their source asset as closely as possible, including editing, saving, thumbnails, and more. Some behavior is restricted such as moving or deleting an alias item.
Aliases can either be created automatically by tagging the asset with the value defined by AliasTagName and giving it a comma-separated list of aliases, or manually managed by calling AddAlias and RemoveAlias. ReconcileAliasesForAsset is provided as a helper function to automatically update new/removed aliases for an existing asset.
Functions
| Type | Name | Description | |
|---|---|---|---|
| void | AddAlias
(
const FAssetData& Asset, |
Add an alias for a given asset. | |
| void | AddAliases
(
const FAssetData& Asset, |
Add a list of aliases for a given asset. | |
| void | Initialize
(
const bool InAutoRegister |
||
| void | LogAliases () |
Logs all the content browser aliases | |
| void | ReconcileAliasesForAsset
(
const FAssetData& Asset, |
Calls AddAlias or RemoveAlias for every alias that doesn't match the stored data for the given asset. | |
| void | ReconcileAliasesFromMetaData
(
const FAssetData& Asset |
Get all aliases from metadata for the given asset, then calls AddAlias or RemoveAlias for every alias that doesn't match the stored data. | |
| void | RemoveAlias
(
const FSoftObjectPath& ObjectPath, |
Remove the given alias from the data source | |
| void | RemoveAliases
(
const FSoftObjectPath& ObjectPath |
Remove all aliases for the given object | |
| void | RemoveAliases
(
const FAssetData& Asset |
Remove all aliases for the given asset |
Overridden from UContentBrowserDataSource
| Type | Name | Description | |
|---|---|---|---|
| bool | AppendItemReference
(
const FContentBrowserItemData& InItem, |
Attempt to append any path references for the given item to the given string. | |
| void | Rebuilds the tree of virtual paths that ends with internal roots | ||
| bool | BulkEditItems
(
TArrayView< const FContentBrowserItemData > InItems |
Attempt to open the given item for editing. | |
| bool | BulkPreviewItems
(
TArrayView< const FContentBrowserItemData > InItems |
Attempt to preview the given items. | |
| bool | BulkPrivatizeItems
(
TArrayView< const FContentBrowserItemData > InItems |
Attempt to mark the given items as private (NotExternallyReferenceable) | |
| bool | BulkSaveItems
(
TArrayView< const FContentBrowserItemData > InItems, |
Attempt to save the given items. | |
| bool | BulkViewItems
(
TArrayView< const FContentBrowserItemData > InItems |
Attempt to open the given items for read-only viewing. | |
| bool | CanEditItem
(
const FContentBrowserItemData& InItem, |
Query whether the given item is can be edited, optionally providing error information if it cannot. | |
| bool | CanPreviewItem
(
const FContentBrowserItemData& InItem, |
Query whether the given item is can be previewed, optionally providing error information if it cannot. | |
| bool | CanPrivatizeItem
(
const FContentBrowserItemData& InItem, |
Query whether the given item can be privatized, optionally providing error information if it cannot. | |
| bool | CanSaveItem
(
const FContentBrowserItemData& InItem, |
Query whether the given item is can be saved, optionally providing error information if it cannot. | |
| bool | CanViewItem
(
const FContentBrowserItemData& InItem, |
Query whether the given item is can be viewed (a read-only asset editor), optionally providing error information if it cannot. | |
| void | ClearCachedFilterData
(
const FContentBrowserDataFilterCacheIDOwner& IDOwner |
Tell the data source to remove the cached data for the filter compilation for this specific owner. | |
| void | CompileFilter
(
const FName InPath, |
Given a path and a data filter, produce an optimized filter that can be used to efficiently enumerate items that match it, and also query whether an item would pass it. | |
| bool | DoesItemPassFilter
(
const FContentBrowserItemData& InItem, |
Query whether the given item passes the given compiled filter. | |
| bool | EditItem
(
const FContentBrowserItemData& InItem |
Attempt to open the given item for editing. | |
| void | EnumerateItemsAtPath
(
const FName InPath, |
Enumerate items that have the given virtual path, optionally filtering by type, and invoking the callback for each matching item. | |
| void | EnumerateItemsMatchingFilter
(
const FContentBrowserDataCompiledFilter& InFilter, |
Enumerate items that match the given compiled filter, invoking the callback for each matching item. | |
| TArray< FContentBrowserItemPath > | GetAliasesForPath
(
const FSoftObjectPath& InInternalPath |
Get a list of other paths that the data source may be using to represent a specific path | |
| bool | GetItemAttribute
(
const FContentBrowserItemData& InItem, |
Query the value of the given attribute on the given item. | |
| bool | GetItemAttributes
(
const FContentBrowserItemData& InItem, |
Query the values of all attributes on the given item. | |
| bool | GetItemPhysicalPath
(
const FContentBrowserItemData& InItem, |
Query the physical (on-disk) path of the given item. | |
| bool | IsItemDirty
(
const FContentBrowserItemData& InItem |
Query whether the given item is considered dirty (ie, has unsaved changes). | |
| bool | Legacy_TryConvertAssetDataToVirtualPath
(
const FAssetData& InAssetData, |
Attempt to convert the given asset data to a virtual path associated with this data source. | |
| bool | Legacy_TryConvertPackagePathToVirtualPath
(
const FName InPackagePath, |
Attempt to convert the given package path to a virtual path associated with this data source. | |
| bool | Legacy_TryGetAssetData
(
const FContentBrowserItemData& InItem, |
Attempt to retrieve the asset data associated with the given item. | |
| bool | Legacy_TryGetPackagePath
(
const FContentBrowserItemData& InItem, |
Legacy functions seem necessary for FrontendFilters to work. | |
| bool | PreviewItem
(
const FContentBrowserItemData& InItem |
Attempt to preview the given item. | |
| bool | PrivatizeItem
(
const FContentBrowserItemData& InItem |
Attempt to mark the given item as private (NotExternallyReferenceable). | |
| void | RemoveUnusedCachedFilterData
(
const FContentBrowserDataFilterCacheIDOwner& IDOwner, |
Tell the data source to remove any cached data for the filter compilation that might not be needed any more. | |
| bool | SaveItem
(
const FContentBrowserItemData& InItem, |
Attempt to save the given item. | |
| void | Shutdown () |
Shutdown this data source instance. | |
| bool | TryGetCollectionId
(
const FContentBrowserItemData& InItem, |
Attempt to retrieve the identifier that should be used when storing a reference to the given item within a collection. | |
| bool | UpdateThumbnail
(
const FContentBrowserItemData& InItem, |
Attempt to update the thumbnail associated with the given item. | |
| bool | ViewItem
(
const FContentBrowserItemData& InItem |
Attempt to open the given item for read-only viewing. |
Constants
| Name | Description |
|---|---|
| AliasTagName | The metadata tag to set for the AliasDataSource to automatically create aliases for an asset |
Deprecated Functions
| Type | Name | Description | |
|---|---|---|---|
| void | RemoveAlias
(
const FName ObjectPath, |
FNames containing full asset paths are deprecated, use FSoftObjectPath instead | |
| void | RemoveAliases
(
const FName ObjectPath |
FNames containing full asset paths are deprecated, use FSoftObjectPath instead |