FContentBrowserItem

Representation of a Content Browser item.

Unreal Engine C++ API Reference > Editor > ContentBrowserData

References

   
Module ContentBrowserData
Header /Engine/Source/Editor/ContentBrowserData/Public/ContentBrowserItem.h
Include #include "ContentBrowserItem.h"

Syntax

struct FContentBrowserItem  

Remarks

Representation of a Content Browser item.

FContentBrowserItem is potentially a composite of multiple internal items (eg, combining equivalent folder items from different data sources), and defers back to these internal items to provide its functionality (via the data source that owns each internal item).

Constructors

Type Name Description
  FContentBrowserItem () Default constructor.
  FContentBrowserItem ( FContentBrowserItemData&& InItem ) Construct this composite item from the given internal item(s).
  FContentBrowserItem ( const FContentBrowserItemData& InI... ) Default constructor.
  FContentBrowserItem ( TArrayView< const FContentBrowserIt... ) Default constructor.
  FContentBrowserItem ( const FContentBrowserItem& ) Copy support.
  FContentBrowserItem ( FContentBrowserItem&& ) Move support.

Functions

Type Name Description
void Append ( const FContentBrowserItem& InOther ) Append the given item to this one, asserting if the combination isn't possible.
void Append ( const FContentBrowserItemData& InO... ) Append the given item to this one, asserting if the combination isn't possible.
bool AppendItemReference ( FString& InOutStr ) Attempt to append any path references for this item to the given string.
bool CanCopy ( const FName InDestPath, FText* OutErrorMsg ) Query whether this item is can be copied, optionally providing error information if it cannot.
bool CanDelete ( FText* OutErrorMsg ) Query whether this item is can be deleted, optionally providing error information if it cannot.
bool CanDuplicate ( FText* OutErrorMsg ) Query whether this item is can be duplicated, optionally providing error information if it cannot.
bool CanEdit ( FText* OutErrorMsg ) Query whether this item is can be edited, optionally providing error information if it cannot.
bool CanMove ( const FName InDestPath, FText* OutErrorMsg ) Query whether this item is can be moved, optionally providing error information if it cannot.
bool CanPreview ( FText* OutErrorMsg ) Query whether this item is can be previewed, optionally providing error information if it cannot.
bool CanRename ( const FString* InNewName, FText* OutErrorMsg ) Query whether this item is can be renamed, optionally providing error information if it cannot.
bool CanSave ( const EContentBrowserItemSaveFlags ..., FText* OutErrorMsg ) Query whether this item is can be saved, optionally providing error information if it cannot.
bool Copy ( const FName InDestPath ) Attempt to copy this item to the given virtual path.
bool Delete () Attempt to delete this item.
FContentBrow... Duplicate () Attempt to begin the process of asynchronously duplicating this item, populating a temporary item that can be finalized or canceled by the user.
bool Edit () Attempt to open this item for editing.
FText GetDisplayName () Get the user-facing name of this item (eg, "MyFile").
FItemDataArr... GetInternalItems () Get the array of internal items that comprise this composite item.
FName GetInternalPath () Gets the internal path if it has one (eg,. "/Game").
FName GetInvariantPath () Gets the path that will not change based on toggling "Show All Folder", "Organize Folders" or other rules (eg,. "/Plugins").
FContentBrow... GetItemAttribute ( const FName InAttributeKey, const bool InIncludeMetaData ) Query the value of the given attribute on this item.
FContentBrow... GetItemAttributes ( const bool InIncludeMetaData ) Query the values of all attributes on this item.
EContentBrow... GetItemCategory () Get the flags denoting the item category information for this item instance.
EContentBrow... GetItemFlags () Get the flags denoting basic state information for this item instance.
FName GetItemName () Get the leaf-name of this item (eg, "MyFile").
bool GetItemPhysicalPath ( FString& OutDiskPath ) Query the physical (on-disk) path of this item.
EContentBrow... GetItemTemporaryReason () Get the flags denoting the item temporary reason information for this item instance.
EContentBrow... GetItemType () Get the flags denoting the item type information for this item instance.
const FConte... GetPrimaryInternalItem () Get the primary internal item from this composite item, if any.
FName GetVirtualPath () Get the complete virtual path that uniquely identifies this item within its owner data source (eg, "/MyRoot/MyFolder/MyFile").
bool IsDirty () Query whether this item is considered dirty (ie, has unsaved changes).
bool IsDisplayOnlyFolder () Check to see whether this item is a display only folder.
bool IsFile () Check to see whether this item is a file.
bool IsFolder () Check to see whether this item is a folder.
bool IsSupported () Check if the item is representing a supported item The content browser can also display some unsupported asset
bool IsTemporary () Check to see whether this item is temporary.
bool IsValid () Check to see whether this item is valid (contains at least one internal item).
bool Legacy_TryGetAssetData ( FAssetData& OutAssetData ) Attempt to retrieve the asset data associated with this item.
bool Legacy_TryGetPackagePath ( FName& OutPackagePath ) Attempt to retrieve the package path associated with this item.
bool Move ( const FName InDestPath ) Attempt to move this item to the given virtual path.
bool Preview () Attempt to preview this item.
void Remove ( const FContentBrowserItemData& InO... ) Remove the given item from this one, asserting if the removal wasn't possible.
void Remove ( const FContentBrowserItem& InOther ) Remove the given item from this one, asserting if the removal wasn't possible.
bool Rename ( const FString& InNewName, FContentBrowserItem* OutNewIte... ) Attempt to rename this item.
bool Save ( const EContentBrowserItemSaveFlags ... ) Attempt to save this item.
bool TryAppend ( const FContentBrowserItem& InOther, FText* OutError ) Attempt to append the given item to this one, providing error information if the combination isn't possible.
bool TryAppend ( const FContentBrowserItemData& InO..., FText* OutError ) Attempt to append the given item to this one, providing error information if the combination isn't possible.
bool TryGetCollectionId ( FSoftObjectPath& OutCollectionId ) Attempt to retrieve the identifier that should be used when storing a reference to this item within a collection.
bool TryRemove ( const FContentBrowserItem& InOther, FText* OutError ) Attempt to remove the given item from this one, providing error information if the removal wasn't possible.
bool TryRemove ( const FContentBrowserItemData& InO..., FText* OutError ) Attempt to remove the given item from this one, providing error information if the removal wasn't possible.
bool UpdateThumbnail ( FAssetThumbnail& InThumbnail ) Attempt to update the thumbnail associated with this item.

Operators

Type Name Description
FContentBrow... operator= ( FContentBrowserItem&& )  
FContentBrow... operator= ( const FContentBrowserItem& )  

Typedefs

Name Description
FItemDataArrayView  

Deprecated Functions

Type Name Description
bool TryGetCollectionId ( FName& OutCollectionId ) FNames containing full object paths are deprecated. Use FSoftObjectPath instead.

Ask questions and help your peers Developer Forums

Write your own tutorials or read those from others Learning Library