docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method CreatePipeline

    CreatePipeline(params Type[])

    Create a new pipeline from stage types.

    Declaration
    public NetworkPipeline CreatePipeline(params Type[] stages)
    Parameters
    Type Name Description
    Type[] stages

    Array of stages the pipeline should contain.

    Returns
    Type Description
    NetworkPipeline
    Remarks

    The order of the different stages is important, as that is the order in which the stages will process a packet when sending messages (the reverse order is used when processing received packets).

    Exceptions
    Type Condition
    InvalidOperationException

    If called after the driver has established connections or before it is created. Note this is only thrown if safety checks are enabled (i.e. in the editor).

    CreatePipeline(NativeArray<NetworkPipelineStageId>)

    Create a new pipeline from stage IDs.

    Declaration
    public NetworkPipeline CreatePipeline(NativeArray<NetworkPipelineStageId> stages)
    Parameters
    Type Name Description
    NativeArray<NetworkPipelineStageId> stages

    Array of stage IDs the pipeline should contain.

    Returns
    Type Description
    NetworkPipeline
    Remarks

    The order of the different stages is important, as that is the order in which the stages will process a packet when sending messages (the reverse order is used when processing received packets).

    Note that this method is Burst-compatible. Note also that no reference to the native array is kept internally by the driver. It is thus safe to dispose of it immediately after calling this method (or to use a temporary allocation for the array).

    Exceptions
    Type Condition
    InvalidOperationException

    If called after the driver has established connections or before it is created. Note this is only thrown if safety checks are enabled (i.e. in the editor).

    In This Article
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023