Search Results for

    Show / Hide Table of Contents
    View Source

    Class BlockEditorData<TValue, TLayout>

    Represents convertible block data from JSON.

    Inheritance
    object
    Namespace: Umbraco.Cms.Core.Models.Blocks
    Assembly: Umbraco.Core.dll
    Syntax
    public class BlockEditorData<TValue, TLayout> where TValue : BlockValue<TLayout>, new() where TLayout : IBlockLayoutItem
    Type Parameters
    Name Description
    TValue

    The type of the block value.

    TLayout

    The type of the layout item.

    Constructors

    View Source

    BlockEditorData(IEnumerable<ContentAndSettingsReference>, TValue)

    Initializes a new instance of the BlockEditorData<TValue, TLayout> class.

    Declaration
    public BlockEditorData(IEnumerable<ContentAndSettingsReference> references, TValue blockValue)
    Parameters
    Type Name Description
    IEnumerable<ContentAndSettingsReference> references

    The content and settings references.

    TValue blockValue

    The block value.

    Exceptions
    Type Condition
    ArgumentNullException

    Thrown when references or blockValue is null.

    Properties

    View Source

    BlockValue

    Gets the reference to the original block value.

    Declaration
    public TValue BlockValue { get; }
    Property Value
    Type Description
    TValue

    The block value.

    View Source

    Empty

    Gets the empty instance of BlockEditorData<TValue, TLayout>.

    Declaration
    public static BlockEditorData<TValue, TLayout> Empty { get; }
    Property Value
    Type Description
    BlockEditorData<TValue, TLayout>

    The empty instance.

    View Source

    Layout

    Gets the layout for this specific property editor.

    Declaration
    public IEnumerable<TLayout>? Layout { get; }
    Property Value
    Type Description
    IEnumerable<TLayout>

    The layout.

    View Source

    References

    Gets the content and settings references.

    Declaration
    public List<ContentAndSettingsReference> References { get; }
    Property Value
    Type Description
    List<ContentAndSettingsReference>

    The references.

    • View Source
    In this article
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX