• Basics
  • Abyss
  • Web APIs
  • C# & Razor
  • .net API
  • JS & TS API
v16
Search Results for

    Show / Hide Table of Contents

    Class StreamMerge

    The base class for all DataSources, especially custom DataSources. It must always be inherited. It provides a lot of core functionality to get configurations, ensure caching and more.

    Important: in most cases you will inherit the CustomDataSource DataSource for custom data sources.

    The StreamMerge DataSource is part of the Standard EAV Data Sources. It will create a new stream containing everything which came into this data source.

    How to use with the VisualQuery

    When using the VisualQuery you can just drag it into your query. This is what it usually looks like:

    The above example shows two filters finding items and delivering them on the same stream.

    Example Using ItemFilterDuplicates

    A common scenario will also combine this using the ItemFilterDuplicates, in case various in-streams deliver the same item:

    No Settings

    The StreamMerge DataSource has no settings to configure.

    Note that it will automatically merge the streams in A-Z order of the In-Stream names.

    Programming With The StreamMerge DataSource

    We recommend to use the VisualQuery where possible, as it's easier to understand and is identical for C# and JavaScript. It's also better because it separates data-retrieval from visualization.

    Read also

    • DataSource / DataStream
    • List of all EAV Data Sources
    • Query / VisualQuery

    Demo App and further links

    You should find some examples in this demo App

    • Demo App with examples for most DataSources

    History

    1. Introduced in EAV 4.x, 2sxc 9.10

    API Documentation

    Inheritance
    object
    ServiceBase
    ServiceBase<DataSourceBase.MyServices>
    DataSourceBase
    StreamMerge
    Implements
    IDataSource
    IAppIdentity
    IZoneIdentity
    IAppIdentityLight
    ICacheKey
    ICacheExpiring
    ITimestamped
    IHasLog
    IDataSourceLinkable
    Inherited Members
    DataSourceBase.Immutable
    DataSourceBase.AppId
    DataSourceBase.ZoneId
    DataSourceBase.Guid
    DataSourceBase.Error
    DataSourceBase.CacheTimestamp
    DataSourceBase.CacheChanged(long)
    DataSourceBase.Configuration
    DataSourceBase.Link
    DataSourceBase.In
    DataSourceBase.Out
    DataSourceBase.this[string]
    DataSourceBase.GetStream(string, string, bool, bool)
    DataSourceBase.List
    DataSourceBase.Attach(IDataSource)
    DataSourceBase.Attach(string, IDataSource, string)
    DataSourceBase.Attach(string, IDataStream)
    Namespace: ToSic.Eav.DataSources
    Assembly: ToSic.Eav.DataSources.dll
    Syntax
    [PublicApi_Stable_ForUseInYourCode]
    [VisualQuery(NiceName = "Merge Streams", UiHint = "Combine multiple streams into one", Icon = "merge_type", Type = DataSourceType.Logic, NameId = "ToSic.Eav.DataSources.StreamMerge, ToSic.Eav.DataSources", DynamicOut = false, DynamicIn = true, HelpLink = "https://go.2sxc.org/DsStreamMerge")]
    public sealed class StreamMerge : DataSourceBase, IDataSource, IAppIdentity, IZoneIdentity, IAppIdentityLight, ICacheKey, ICacheExpiring, ITimestamped, IHasLog, IDataSourceLinkable
    Remarks

    Had a major, breaking update in v15. Consult the guide to upgrade your custom data sources.

    Implements

    IDataSource
    IAppIdentity
    IZoneIdentity
    IAppIdentityLight
    ICacheKey
    ICacheExpiring
    ITimestamped
    IHasLog
    IDataSourceLinkable
    • Improve this Doc
    • View Source
    In This Article
    Back to top Generated by DocFX