November Happy Hour will be moved to Thursday December 5th.

Class SoftLinkDataSource

Provides SoftLink data to DataBoundControl implementations.

Inheritance
System.Object
GenericDataSource<SoftLink, System.Collections.Generic.List<SoftLink>, System.String>
SoftLinkDataSource
Implements
Inherited Members
Namespace: EPiServer.Web.WebControls
Assembly: EPiServer.Cms.AspNet.dll
Version: 11.20.7
Syntax
public class SoftLinkDataSource : GenericDataSource<SoftLink, List<SoftLink>, string>, IDataSourceMethods

Constructors

SoftLinkDataSource()

Declaration
public SoftLinkDataSource()

Properties

CanDelete

Gets a value indicating whether SoftLinkDataSource supports instance deletion, which it does not.

Declaration
protected override bool CanDelete { get; }
Property Value
Type Description
System.Boolean

false

Overrides
EPiServer.Web.WebControls.GenericDataSource<EPiServer.DataAbstraction.SoftLink, System.Collections.Generic.List<EPiServer.DataAbstraction.SoftLink>, System.String>.CanDelete

CanInsert

Gets a value indicating whether SoftLinkDataSource supports instance insertions, which it does not.

Declaration
protected override bool CanInsert { get; }
Property Value
Type Description
System.Boolean

false

Overrides
EPiServer.Web.WebControls.GenericDataSource<EPiServer.DataAbstraction.SoftLink, System.Collections.Generic.List<EPiServer.DataAbstraction.SoftLink>, System.String>.CanInsert

CanUpdate

Gets a value indicating whether SoftLinkDataSource supports instance updates, which it does not.

Declaration
protected override bool CanUpdate { get; }
Property Value
Type Description
System.Boolean

false

Overrides
EPiServer.Web.WebControls.GenericDataSource<EPiServer.DataAbstraction.SoftLink, System.Collections.Generic.List<EPiServer.DataAbstraction.SoftLink>, System.String>.CanUpdate

ListReferencing

Gets or sets a value indicating whether links referencing the page specified by PageLink should be listed. If not, all links present in the page specified by PageLink are listed which is the default behaviour.

Declaration
public bool ListReferencing { get; set; }
Property Value
Type Description
System.Boolean

Gets or sets a reference to a page that will scope the set of SoftLinks

Declaration
public PageReference PageLink { get; set; }
Property Value
Type Description
PageReference

SoftLinkRepository

Gets or sets the PropertyResolver that should be used by the current control instance.

Declaration
protected Injected<IContentSoftLinkRepository> SoftLinkRepository { get; set; }
Property Value
Type Description
Injected<IContentSoftLinkRepository>

Methods

Creates a new SoftLink instance

Declaration
protected override SoftLink CreateItem(List<SoftLink> items)
Parameters
Type Name Description
System.Collections.Generic.List<SoftLink> items

the list of current instances in the given scope.

Returns
Type Description
SoftLink
Overrides
EPiServer.Web.WebControls.GenericDataSource<EPiServer.DataAbstraction.SoftLink, System.Collections.Generic.List<EPiServer.DataAbstraction.SoftLink>, System.String>.CreateItem(System.Collections.Generic.List<EPiServer.DataAbstraction.SoftLink>)

Deletes an item. Is not supported by SoftLinkDataSource. Throws NotSupportedException

Declaration
protected override void DeleteItem(SoftLink item)
Parameters
Type Name Description
SoftLink item

The item to delete.

Overrides
EPiServer.Web.WebControls.GenericDataSource<EPiServer.DataAbstraction.SoftLink, System.Collections.Generic.List<EPiServer.DataAbstraction.SoftLink>, System.String>.DeleteItem(EPiServer.DataAbstraction.SoftLink)

ListItems()

Override to return a list of instances.

Declaration
protected override List<SoftLink> ListItems()
Returns
Type Description
System.Collections.Generic.List<SoftLink>

a list of instances.

Overrides
EPiServer.Web.WebControls.GenericDataSource<EPiServer.DataAbstraction.SoftLink, System.Collections.Generic.List<EPiServer.DataAbstraction.SoftLink>, System.String>.ListItems()

LoadItem(String)

Load an item with the specified key. Is not supported by SoftLinkDataSource

Declaration
protected override SoftLink LoadItem(string key)
Parameters
Type Name Description
System.String key

The key of the instance to load.

Returns
Type Description
SoftLink

NotSupportedException

Overrides
EPiServer.Web.WebControls.GenericDataSource<EPiServer.DataAbstraction.SoftLink, System.Collections.Generic.List<EPiServer.DataAbstraction.SoftLink>, System.String>.LoadItem(System.String)

Saves an item. Is not supported by SoftLinkDataSource. Throws NotSupportedException

Declaration
protected override void SaveItem(SoftLink item)
Parameters
Type Name Description
SoftLink item

The item to persist.

Overrides
EPiServer.Web.WebControls.GenericDataSource<EPiServer.DataAbstraction.SoftLink, System.Collections.Generic.List<EPiServer.DataAbstraction.SoftLink>, System.String>.SaveItem(EPiServer.DataAbstraction.SoftLink)

Implements

Extension Methods