示例#1
0
        /// <summary>
        /// Convert from <see cref="TenantOffset"/> to <see cref="TenantOffset"/>
        /// </summary>
        /// /// <param name="tenantOffset"><see cref="TenantOffset"/> to convert from</param>
        /// <returns>Converted <see cref="Runtime.Grpc.Interaction.TenantOffset"/></returns>
        public static Runtime.Grpc.Interaction.TenantOffset ToProtobuf(this TenantOffset tenantOffset)
        {
            var message = new Runtime.Grpc.Interaction.TenantOffset();

            message.Tenant = tenantOffset.Tenant.ToProtobuf();
            message.Offset = tenantOffset.Offset;
            return(message);
        }
示例#2
0
 /// <summary>
 /// Convert from <see cref="Runtime.Grpc.Interaction.TenantOffset"/> to <see cref="TenantOffset"/>
 /// </summary>
 /// <param name="tenantOffset"><see cref="Runtime.Grpc.Interaction.TenantOffset"/> to convert from</param>
 /// <returns>Converted <see cref="TenantOffset"/></returns>
 public static TenantOffset ToTenantOffset(this Runtime.Grpc.Interaction.TenantOffset tenantOffset)
 {
     return(new TenantOffset(
                tenantOffset.Tenant.ToConcept <TenantId>(),
                tenantOffset.Offset));
 }