forked from Azure/DotNetty
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathIByteBufferHolder.cs
35 lines (29 loc) · 1.18 KB
/
IByteBufferHolder.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
// Copyright (c) Microsoft. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
namespace DotNetty.Buffers
{
using DotNetty.Common;
public interface IByteBufferHolder : IReferenceCounted
{
/// <summary>
/// Return the data which is held by this {@link ByteBufHolder}.
/// </summary>
IByteBuffer Content { get; }
/// <summary>
/// Create a deep copy of this {@link ByteBufHolder}.
/// </summary>
IByteBufferHolder Copy();
/// <summary>
/// Duplicate the {@link ByteBufHolder}. Be aware that this will not automatically call {@link #retain()}.
/// </summary>
IByteBufferHolder Duplicate();
/// <summary>
/// Duplicates this {@link ByteBufHolder}. This method returns a retained duplicate unlike {@link #duplicate()}.
/// </summary>
IByteBufferHolder RetainedDuplicate();
/// <summary>
/// Returns a new {@link ByteBufHolder} which contains the specified {@code content}.
/// </summary>
IByteBufferHolder Replace(IByteBuffer content);
}
}