docs.unity.cn
    Show / Hide Table of Contents

    Class FragmentationStageParameterExtensions

    Extensions for FragmentationUtility.Parameters.

    Inheritance
    Object
    FragmentationStageParameterExtensions
    Inherited Members
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: Unity.Networking.Transport.Utilities
    Syntax
    public static class FragmentationStageParameterExtensions

    Methods

    GetFragmentationStageParameters(ref NetworkSettings)

    Gets the FragmentationUtility.Parameters in the settings.

    Declaration
    public static FragmentationUtility.Parameters GetFragmentationStageParameters(this ref NetworkSettings settings)
    Parameters
    Type Name Description
    NetworkSettings settings

    Settings to get parameters from.

    Returns
    Type Description
    FragmentationUtility.Parameters

    Structure containing the fragmentation parameters.

    WithFragmentationStageParameters(ref NetworkSettings, Int32)

    Sets the FragmentationUtility.Parameters in the settings.

    Declaration
    public static ref NetworkSettings WithFragmentationStageParameters(this ref NetworkSettings settings, int payloadCapacity = 4096)
    Parameters
    Type Name Description
    NetworkSettings settings

    Settings to modify.

    Int32 payloadCapacity

    Maximum size that can be fragmented by the FragmentationPipelineStage. Attempting to send a message larger than that will result in the send operation returning NetworkPacketOverflow. Maximum value is ~20MB for unreliable packets, and ~88KB for reliable ones.

    Returns
    Type Description
    NetworkSettings

    Settings structure with modified values.

    Back to top Copyright © 2023 Unity Technologies — Terms of use
    Generated by DocFX
    on Thursday, June 1, 2023