You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
176 lines
3.7 KiB
176 lines
3.7 KiB
// Copyright Epic Games, Inc. All Rights Reserved.
|
|
// This file is automatically generated. Changes to this file may be overwritten.
|
|
|
|
namespace Epic.OnlineServices.P2P
|
|
{
|
|
/// <summary>
|
|
/// Structure containing information about an connection request that is being closed.
|
|
/// </summary>
|
|
public struct OnRemoteConnectionClosedInfo : ICallbackInfo
|
|
{
|
|
/// <summary>
|
|
/// Client-specified data passed into <see cref="Presence.PresenceInterface.AddNotifyOnPresenceChanged" />
|
|
/// </summary>
|
|
public object ClientData { get; set; }
|
|
|
|
/// <summary>
|
|
/// The local user who is being notified of a connection being closed
|
|
/// </summary>
|
|
public ProductUserId LocalUserId { get; set; }
|
|
|
|
/// <summary>
|
|
/// The Product User ID of the remote user who this connection was with
|
|
/// </summary>
|
|
public ProductUserId RemoteUserId { get; set; }
|
|
|
|
/// <summary>
|
|
/// The socket ID of the connection being closed
|
|
/// </summary>
|
|
public SocketId? SocketId { get; set; }
|
|
|
|
/// <summary>
|
|
/// The reason the connection was closed (if known)
|
|
/// </summary>
|
|
public ConnectionClosedReason Reason { get; set; }
|
|
|
|
public Result? GetResultCode()
|
|
{
|
|
return null;
|
|
}
|
|
|
|
internal void Set(ref OnRemoteConnectionClosedInfoInternal other)
|
|
{
|
|
ClientData = other.ClientData;
|
|
LocalUserId = other.LocalUserId;
|
|
RemoteUserId = other.RemoteUserId;
|
|
SocketId = other.SocketId;
|
|
Reason = other.Reason;
|
|
}
|
|
}
|
|
|
|
[System.Runtime.InteropServices.StructLayout(System.Runtime.InteropServices.LayoutKind.Sequential, Pack = 8)]
|
|
internal struct OnRemoteConnectionClosedInfoInternal : ICallbackInfoInternal, IGettable<OnRemoteConnectionClosedInfo>, ISettable<OnRemoteConnectionClosedInfo>, System.IDisposable
|
|
{
|
|
private System.IntPtr m_ClientData;
|
|
private System.IntPtr m_LocalUserId;
|
|
private System.IntPtr m_RemoteUserId;
|
|
private System.IntPtr m_SocketId;
|
|
private ConnectionClosedReason m_Reason;
|
|
|
|
public object ClientData
|
|
{
|
|
get
|
|
{
|
|
object value;
|
|
Helper.Get(m_ClientData, out value);
|
|
return value;
|
|
}
|
|
|
|
set
|
|
{
|
|
Helper.Set(value, ref m_ClientData);
|
|
}
|
|
}
|
|
|
|
public System.IntPtr ClientDataAddress
|
|
{
|
|
get
|
|
{
|
|
return m_ClientData;
|
|
}
|
|
}
|
|
|
|
public ProductUserId LocalUserId
|
|
{
|
|
get
|
|
{
|
|
ProductUserId value;
|
|
Helper.Get(m_LocalUserId, out value);
|
|
return value;
|
|
}
|
|
|
|
set
|
|
{
|
|
Helper.Set(value, ref m_LocalUserId);
|
|
}
|
|
}
|
|
|
|
public ProductUserId RemoteUserId
|
|
{
|
|
get
|
|
{
|
|
ProductUserId value;
|
|
Helper.Get(m_RemoteUserId, out value);
|
|
return value;
|
|
}
|
|
|
|
set
|
|
{
|
|
Helper.Set(value, ref m_RemoteUserId);
|
|
}
|
|
}
|
|
|
|
public SocketId? SocketId
|
|
{
|
|
get
|
|
{
|
|
SocketId? value;
|
|
Helper.Get<SocketIdInternal, SocketId>(m_SocketId, out value);
|
|
return value;
|
|
}
|
|
|
|
set
|
|
{
|
|
Helper.Set<SocketId, SocketIdInternal>(ref value, ref m_SocketId);
|
|
}
|
|
}
|
|
|
|
public ConnectionClosedReason Reason
|
|
{
|
|
get
|
|
{
|
|
return m_Reason;
|
|
}
|
|
|
|
set
|
|
{
|
|
m_Reason = value;
|
|
}
|
|
}
|
|
|
|
public void Set(ref OnRemoteConnectionClosedInfo other)
|
|
{
|
|
ClientData = other.ClientData;
|
|
LocalUserId = other.LocalUserId;
|
|
RemoteUserId = other.RemoteUserId;
|
|
SocketId = other.SocketId;
|
|
Reason = other.Reason;
|
|
}
|
|
|
|
public void Set(ref OnRemoteConnectionClosedInfo? other)
|
|
{
|
|
if (other.HasValue)
|
|
{
|
|
ClientData = other.Value.ClientData;
|
|
LocalUserId = other.Value.LocalUserId;
|
|
RemoteUserId = other.Value.RemoteUserId;
|
|
SocketId = other.Value.SocketId;
|
|
Reason = other.Value.Reason;
|
|
}
|
|
}
|
|
|
|
public void Dispose()
|
|
{
|
|
Helper.Dispose(ref m_ClientData);
|
|
Helper.Dispose(ref m_LocalUserId);
|
|
Helper.Dispose(ref m_RemoteUserId);
|
|
Helper.Dispose(ref m_SocketId);
|
|
}
|
|
|
|
public void Get(out OnRemoteConnectionClosedInfo output)
|
|
{
|
|
output = new OnRemoteConnectionClosedInfo();
|
|
output.Set(ref this);
|
|
}
|
|
}
|
|
}
|