Interface IAsset
Describes an ADAM (Automatic Digital Asset Management) asset.
This contains properties which both IFolder and IFile have in common
in addition to what they inherit from the EAV
[PublicApi]
public interface IAsset : IHasMetadata
Properties
HasMetadata
Tells you if this asset has real metadata attached or not.
bool HasMetadata { get; }
Property Value
- bool
true
if this asset has metadata,false
if it doesn't (in which case the Metadata property still works, but won't deliver any real values)
Metadata
List of metadata items - will automatically contain a fake item, even if no metadata exits to help in razor template etc.
IMetadata Metadata { get; }
Property Value
- IMetadata
An
IMetadata
which contains the metadata, or an empty IMetadata which still works if no metadata exists.
Type
The type of this asset (folder, file, etc.) - typically for adding icons or similar when listing assets.
string Type { get; }
Property Value
- string
folder
,image
,document
,file
depending on what it is.document
forC:\Inetpub\wwwroot\www.2sic.com\Portals\0\2sxc\content\assets\docs\terms\file.pdf
Url
The path to this asset as used from external access. Must be a full url beginning with a "/" like "/Portals/0/adam/..."
string Url { get; }
Property Value
- string
The url to this asset.
/Portals/0/2sxc/content/assets/docs/terms/file.pdf
forC:\Inetpub\wwwroot\www.2sic.com\Portals\0\2sxc\content\assets\docs\terms\file.pdf