1 using System;
2 using Couchbase.Core.IO.Converters;
3 
4 namespace Couchbase.Core.IO.Operations
5 {
6     internal class GetT<T> : MutationOperationBase<T>
7     {
GetT(string bucketName, string key)8         internal GetT(string bucketName, string key) : base(bucketName, key)
9         { }
10 
WriteExtras(OperationBuilder builder)11         protected override void WriteExtras(OperationBuilder builder)
12         {
13             Span<byte> extras = stackalloc byte[4];
14             ByteConverter.FromUInt32(Expires, extras);
15             builder.Write(extras);
16         }
17 
WriteBody(OperationBuilder builder)18         protected override void WriteBody(OperationBuilder builder)
19         {
20         }
21 
22         public override OpCode OpCode => OpCode.GAT;
23     }
24 }
25 
26 #region [ License information          ]
27 
28 /* ************************************************************
29  *
30  *    @author Couchbase <info@couchbase.com>
31  *    @copyright 2017 Couchbase, Inc.
32  *
33  *    Licensed under the Apache License, Version 2.0 (the "License");
34  *    you may not use this file except in compliance with the License.
35  *    You may obtain a copy of the License at
36  *
37  *        http://www.apache.org/licenses/LICENSE-2.0
38  *
39  *    Unless required by applicable law or agreed to in writing, software
40  *    distributed under the License is distributed on an "AS IS" BASIS,
41  *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
42  *    See the License for the specific language governing permissions and
43  *    limitations under the License.
44  *
45  * ************************************************************/
46 
47 #endregion
48