Пример #1
0
        /// <summary>
        /// Creates a new message builder and runs <see cref="StringExtensions.Wrap"/> on the result with width 35 and newline "\u0011".
        /// </summary>
        /// <param name="this"></param>
        /// <param name="action"></param>
        /// <returns></returns>
        public static MessageEntryBuilder.MessageBuilder CompileTimeWrap(this MessageEntryBuilder.MessageBuilder @this, Action <MessageEntryBuilder.MessageBuilder> action)
        {
            var wrappedMessageBuilder = new MessageEntryBuilder.MessageBuilder();

            action(wrappedMessageBuilder);
            var message = wrappedMessageBuilder.Build().Wrap(35, "\u0011", "\u0010");

            return(@this.Text(message));
        }