aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Embedded_SW/Embedded/Communication/PMR/ThreadLoading/AttemptThreadJoggingRequest.pb-c.c
blob: 78659ae902e79a17961aca3870eb76f105ce43ee (plain)
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
/* Generated by the protocol buffer compiler.  DO NOT EDIT! */
/* Generated from: AttemptThreadJoggingRequest.proto */

/* Do not generate deprecated warnings for self */
#ifndef PROTOBUF_C__NO_DEPRECATED
#define PROTOBUF_C__NO_DEPRECATED
#endif

#include "AttemptThreadJoggingRequest.pb-c.h"
void   attempt_thread_jogging_request__init
                     (AttemptThreadJoggingRequest         *message)
{
  static const AttemptThreadJoggingRequest init_value = ATTEMPT_THREAD_JOGGING_REQUEST__INIT;
  *message = init_value;
}
size_t attempt_thread_jogging_request__get_packed_size
                     (const AttemptThreadJoggingRequest *message)
{
  assert(message->base.descriptor == &attempt_thread_jogging_request__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t attempt_thread_jogging_request__pack
                     (const AttemptThreadJoggingRequest *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &attempt_thread_jogging_request__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t attempt_thread_jogging_request__pack_to_buffer
                     (const AttemptThreadJoggingRequest *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &attempt_thread_jogging_request__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
AttemptThreadJoggingRequest *
       attempt_thread_jogging_request__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (AttemptThreadJoggingRequest *)
     protobuf_c_message_unpack (&attempt_thread_jogging_request__descriptor,
                                allocator, len, data);
}
void   attempt_thread_jogging_request__free_unpacked
                     (AttemptThreadJoggingRequest *message,
                      ProtobufCAllocator *allocator)
{
  if(!message)
    return;
  assert(message->base.descriptor == &attempt_thread_jogging_request__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
#define attempt_thread_jogging_request__field_descriptors NULL
#define attempt_thread_jogging_request__field_indices_by_name NULL
#define attempt_thread_jogging_request__number_ranges NULL
const ProtobufCMessageDescriptor attempt_thread_jogging_request__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "",
  "",
  "",
  "",
  sizeof(AttemptThreadJoggingRequest),
  0,
  attempt_thread_jogging_request__field_descriptors,
  attempt_thread_jogging_request__field_indices_by_name,
  0,  attempt_thread_jogging_request__number_ranges,
  (ProtobufCMessageInit) attempt_thread_jogging_request__init,
  NULL,NULL,NULL    /* reserved[123] */
};
span class="k">if (inlineRun != null) { inlineRun.VisualLine = VisualLine; VisualLine.hasInlineObjects = true; TextView.AddInlineObject(inlineRun); } return run; } } if (TextView.Options.ShowEndOfLine && textSourceCharacterIndex == VisualLine.VisualLength) { return CreateTextRunForNewLine(); } return new TextEndOfParagraph(1); } catch (Exception ex) { Debug.WriteLine(ex.ToString()); throw; } } TextRun CreateTextRunForNewLine() { string newlineText = ""; DocumentLine lastDocumentLine = VisualLine.LastDocumentLine; if (lastDocumentLine.DelimiterLength == 2) { newlineText = "¶"; } else if (lastDocumentLine.DelimiterLength == 1) { char newlineChar = Document.GetCharAt(lastDocumentLine.Offset + lastDocumentLine.Length); if (newlineChar == '\r') newlineText = "\\r"; else if (newlineChar == '\n') newlineText = "\\n"; else newlineText = "?"; } return new FormattedTextRun(new FormattedTextElement(TextView.cachedElements.GetTextForNonPrintableCharacter(newlineText, this), 0), GlobalTextRunProperties); } public override TextSpan<CultureSpecificCharacterBufferRange> GetPrecedingText(int textSourceCharacterIndexLimit) { try { foreach (VisualLineElement element in VisualLine.Elements) { if (textSourceCharacterIndexLimit > element.VisualColumn && textSourceCharacterIndexLimit <= element.VisualColumn + element.VisualLength) { TextSpan<CultureSpecificCharacterBufferRange> span = element.GetPrecedingText(textSourceCharacterIndexLimit, this); if (span == null) break; int relativeOffset = textSourceCharacterIndexLimit - element.VisualColumn; if (span.Length > relativeOffset) throw new ArgumentException("The returned TextSpan is too long.", element.GetType().Name + ".GetPrecedingText"); return span; } } CharacterBufferRange empty = CharacterBufferRange.Empty; return new TextSpan<CultureSpecificCharacterBufferRange>(empty.Length, new CultureSpecificCharacterBufferRange(null, empty)); } catch (Exception ex) { Debug.WriteLine(ex.ToString()); throw; } } public override int GetTextEffectCharacterIndexFromTextSourceCharacterIndex(int textSourceCharacterIndex) { throw new NotSupportedException(); } string cachedString; int cachedStringOffset; public StringSegment GetText(int offset, int length) { if (cachedString != null) { if (offset >= cachedStringOffset && offset + length <= cachedStringOffset + cachedString.Length) { return new StringSegment(cachedString, offset - cachedStringOffset, length); } } cachedStringOffset = offset; return new StringSegment(cachedString = this.Document.GetText(offset, length)); } } }