File: classlog4cxx_1_1_n_d_c.html

package info (click to toggle)
log4cxx 0.10.0-4
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 17,028 kB
  • ctags: 6,434
  • sloc: cpp: 33,940; sh: 8,852; xml: 4,686; makefile: 508; java: 48
file content (1155 lines) | stat: -rw-r--r-- 63,000 bytes parent folder | download | duplicates (5)
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
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<!--

 Licensed to the Apache Software Foundation (ASF) under one or more
 contributor license agreements.  See the NOTICE file distributed with
 this work for additional information regarding copyright ownership.
 The ASF licenses this file to You under the Apache License, Version 2.0
 (the "License"); you may not use this file except in compliance with
 the License.  You may obtain a copy of the License at

      http://www.apache.org/licenses/LICENSE-2.0

 Unless required by applicable law or agreed to in writing, software
 distributed under the License is distributed on an "AS IS" BASIS,
 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 See the License for the specific language governing permissions and
 limitations under the License.

--><html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>Apache log4cxx: NDC Class Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.4.6 -->
<div class="tabs">
  <ul>
    <li><a href="main.html"><span>Main&nbsp;Page</span></a></li>
    <li><a href="modules.html"><span>Modules</span></a></li>
    <li><a href="namespaces.html"><span>Namespaces</span></a></li>
    <li id="current"><a href="classes.html"><span>Classes</span></a></li>
    <li><a href="files.html"><span>Files</span></a></li>
  </ul></div>
<div class="tabs">
  <ul>
    <li><a href="classes.html"><span>Alphabetical&nbsp;List</span></a></li>
    <li><a href="annotated.html"><span>Class&nbsp;List</span></a></li>
    <li><a href="hierarchy.html"><span>Class&nbsp;Hierarchy</span></a></li>
    <li><a href="functions.html"><span>Class&nbsp;Members</span></a></li>
  </ul></div>
<div class="nav">
<a class="el" href="namespacelog4cxx.html">log4cxx</a>::<a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a></div>
<h1>NDC Class Reference</h1><!-- doxytag: class="log4cxx::NDC" --><a href="classlog4cxx_1_1_n_d_c-members.html">List of all members.</a><hr><a name="_details"></a><h2>Detailed Description</h2>
the ndc class implements <em>nested diagnostic contexts</em> as defined by neil harrison in the article "patterns for logging diagnostic messages" part of the book "<em>pattern languages of program design 3</em>" edited by martin et al. 
<p>
a nested diagnostic context, or ndc in short, is an instrument to distinguish interleaved log output from different sources. log output is typically interleaved when a server handles multiple clients near-simultaneously.<p>
interleaved log output can still be meaningful if each log entry from different contexts had a distinctive stamp. this is where ndcs come into play.<p>
<em><b>note that ndcs are managed on a per thread basis</b></em>. ndc operations such as <a class="el" href="classlog4cxx_1_1_n_d_c.html#670a4077b7624737946c2a15817dfcee">push</a>, <a class="el" href="classlog4cxx_1_1_n_d_c.html#300d98eecc81234f5ed86cfb3b41b548">pop</a>, <a class="el" href="classlog4cxx_1_1_n_d_c.html#14dabca7589b28dc6adca2c5367546e1">clear</a> and <a class="el" href="classlog4cxx_1_1_n_d_c.html#b275726b46a696f8b20c4a23113230d9">getDepth</a> affect the ndc of the <em>current</em> thread only. ndcs of other threads remain unaffected.<p>
for example, a servlet can build a per client request ndc consisting the clients host name and other information contained in the the request. <em>cookies</em> are another source of distinctive information. to build an ndc one uses the <a class="el" href="classlog4cxx_1_1_n_d_c.html#670a4077b7624737946c2a15817dfcee">push</a> operation. simply put,<p>
<ul>
<li>
contexts can be nested.<p>
<p>
</li>
<li>
when entering a context, call <code>ndc.push</code>. as a side effect, if there is no nested diagnostic context for the current thread, this method will create it.<p>
<p>
</li>
<li>
when leaving a context, call <code>ndc.pop</code>.<p>
<p>
</li>
<li>
<b>when exiting a thread make sure to call <a class="el" href="classlog4cxx_1_1_n_d_c.html#f54fd13c5dd6e2cd20190d8ce7b3125d">remove</a> </b>. </li>
</ul>
<p>
there is no penalty for forgetting to match each <code>push</code> operation with a corresponding <code>pop</code>, except the obvious mismatch between the real application context and the context set in the ndc.<p>
if configured to do so, <a class="el" href="classlog4cxx_1_1_pattern_layout.html">PatternLayout</a> and <a class="el" href="classlog4cxx_1_1_t_t_c_c_layout.html">TTCCLayout</a> instances automatically retrieve the nested diagnostic context for the current thread without any user intervention. hence, even if a servlet is serving multiple clients simultaneously, the logs emanating from the same code (belonging to the same logger) can still be distinguished because each client request will have a different ndc tag.<p>
heavy duty systems should call the <a class="el" href="classlog4cxx_1_1_n_d_c.html#f54fd13c5dd6e2cd20190d8ce7b3125d">remove</a> method when leaving the run method of a thread. this ensures that the memory used by the thread can be freed by the java garbage collector. there is a mechanism to lazily remove references to dead threads. in practice, this means that you can be a little sloppy and sometimes forget to call <a class="el" href="classlog4cxx_1_1_n_d_c.html#f54fd13c5dd6e2cd20190d8ce7b3125d">remove</a> before exiting a thread. 
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Public Types</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef std::pair&lt; <a class="el" href="namespacelog4cxx.html#d7ec98d27bca7666e23f27dd1fb181c8">LogString</a>,<br>
 <a class="el" href="namespacelog4cxx.html#d7ec98d27bca7666e23f27dd1fb181c8">LogString</a> &gt;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#06fd35d312837c220d1781b630646621">DiagnosticContext</a></td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Pair of Message and FullMessage.  <a href="#06fd35d312837c220d1781b630646621"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef std::stack&lt; <a class="el" href="classlog4cxx_1_1_n_d_c.html#06fd35d312837c220d1781b630646621">DiagnosticContext</a> &gt;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#d27ab948303a389e8150ec1d837f1736">Stack</a></td></tr>

<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#8ec640ca3549a71be17f9fff55d4b6b8">NDC</a> (const std::string &amp;message)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Creates a nested diagnostic context.  <a href="#8ec640ca3549a71be17f9fff55d4b6b8"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#7be25f4d39f960d05de41a18af9dabf1">~NDC</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Removes the topmost element from the <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> stack.  <a href="#7be25f4d39f960d05de41a18af9dabf1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#8eac1aac9c4cc771421d583b886d2cb3">NDC</a> (const std::wstring &amp;message)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Creates a nested diagnostic context.  <a href="#8eac1aac9c4cc771421d583b886d2cb3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#8a2cd4b0aa44ad594cfcb387751f197a">NDC</a> (const std::basic_string&lt; <a class="el" href="namespacelog4cxx.html#7edf438a3547255847b2b903b1a36aaf">UniChar</a> &gt; &amp;message)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Creates a nested diagnostic context.  <a href="#8a2cd4b0aa44ad594cfcb387751f197a"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#4c14d449acdaeb48752b95840b3a7391">NDC</a> (const <a class="el" href="logstring_8h.html#782e95610ad4dd24aee670f3b5846a3b">CFStringRef</a> &amp;message)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Creates a nested diagnostic context.  <a href="#4c14d449acdaeb48752b95840b3a7391"></a><br></td></tr>
<tr><td colspan="2"><br><h2>Static Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#14dabca7589b28dc6adca2c5367546e1">clear</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Clear any nested diagnostic information if any.  <a href="#14dabca7589b28dc6adca2c5367546e1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static <a class="el" href="classlog4cxx_1_1_n_d_c.html#d27ab948303a389e8150ec1d837f1736">Stack</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#08f7cc8fa9fa9746b69f0bef73e07044">cloneStack</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Clone the diagnostic context for the current thread.  <a href="#08f7cc8fa9fa9746b69f0bef73e07044"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#078b713ccf74bf2628b2230fbe597d41">inherit</a> (<a class="el" href="classlog4cxx_1_1_n_d_c.html#d27ab948303a389e8150ec1d837f1736">Stack</a> *stack)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Inherit the diagnostic context of another thread.  <a href="#078b713ccf74bf2628b2230fbe597d41"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#ec930584769a8379ff4ee6ecd2448508">get</a> (<a class="el" href="namespacelog4cxx.html#d7ec98d27bca7666e23f27dd1fb181c8">LogString</a> &amp;dest)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the current value of the <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> of the currrent thread.  <a href="#ec930584769a8379ff4ee6ecd2448508"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#b275726b46a696f8b20c4a23113230d9">getDepth</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the current nesting depth of this diagnostic context.  <a href="#b275726b46a696f8b20c4a23113230d9"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#cb0b14918df8211fb25cb23bd0384d51">empty</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Tests if the <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> is empty.  <a href="#cb0b14918df8211fb25cb23bd0384d51"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static <a class="el" href="namespacelog4cxx.html#d7ec98d27bca7666e23f27dd1fb181c8">LogString</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#300d98eecc81234f5ed86cfb3b41b548">pop</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Pop top value off stack.  <a href="#300d98eecc81234f5ed86cfb3b41b548"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#3d0d9f6e0412585ec1e9b372f9bac6b0">pop</a> (std::string &amp;buf)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Pop top value off stack.  <a href="#3d0d9f6e0412585ec1e9b372f9bac6b0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static <a class="el" href="namespacelog4cxx.html#d7ec98d27bca7666e23f27dd1fb181c8">LogString</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#79fee8d99de96898fbe985d692b5cfe1">peek</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Looks at the last diagnostic context at the top of this <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> without removing it.  <a href="#79fee8d99de96898fbe985d692b5cfe1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#ca6fa7a1575b839b4f8ac9a60ec6c2d1">peek</a> (std::string &amp;buf)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get top value without removing value.  <a href="#ca6fa7a1575b839b4f8ac9a60ec6c2d1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#670a4077b7624737946c2a15817dfcee">push</a> (const std::string &amp;message)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Push new diagnostic context information for the current thread.  <a href="#670a4077b7624737946c2a15817dfcee"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#db03ca6083676de6be2adf9346f12a89">pushLS</a> (const <a class="el" href="namespacelog4cxx.html#d7ec98d27bca7666e23f27dd1fb181c8">LogString</a> &amp;message)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Push new diagnostic context information for the current thread.  <a href="#db03ca6083676de6be2adf9346f12a89"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#f54fd13c5dd6e2cd20190d8ce7b3125d">remove</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Remove the diagnostic context for this thread.  <a href="#f54fd13c5dd6e2cd20190d8ce7b3125d"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#ccac902acd908c0dff6601c7a861785e">push</a> (const std::wstring &amp;message)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Push new diagnostic context information for the current thread.  <a href="#ccac902acd908c0dff6601c7a861785e"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#a7420cde96c577e4c6a08354c7725ebd">peek</a> (std::wstring &amp;dst)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Appends the current <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> content to the provided string.  <a href="#a7420cde96c577e4c6a08354c7725ebd"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#2667d6cbcbc31976468db35bf2e24778">pop</a> (std::wstring &amp;dst)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Appends the current <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> content to the provided string and removes the value from the <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a>.  <a href="#2667d6cbcbc31976468db35bf2e24778"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#67f283cbdbf951781c6f24f93b000fa1">push</a> (const std::basic_string&lt; <a class="el" href="namespacelog4cxx.html#7edf438a3547255847b2b903b1a36aaf">UniChar</a> &gt; &amp;message)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Push new diagnostic context information for the current thread.  <a href="#67f283cbdbf951781c6f24f93b000fa1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#64259a85df3a8f1e3b00d5c71bc808ff">peek</a> (std::basic_string&lt; <a class="el" href="namespacelog4cxx.html#7edf438a3547255847b2b903b1a36aaf">UniChar</a> &gt; &amp;dst)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Appends the current <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> content to the provided string.  <a href="#64259a85df3a8f1e3b00d5c71bc808ff"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#c71838e8767dd3c956b3f4774d945d5f">pop</a> (std::basic_string&lt; <a class="el" href="namespacelog4cxx.html#7edf438a3547255847b2b903b1a36aaf">UniChar</a> &gt; &amp;dst)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Appends the current <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> content to the provided string and removes the value from the <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a>.  <a href="#c71838e8767dd3c956b3f4774d945d5f"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#e579f7b51f97fab7dfa2d3217b1ceaab">push</a> (const <a class="el" href="logstring_8h.html#782e95610ad4dd24aee670f3b5846a3b">CFStringRef</a> &amp;message)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Push new diagnostic context information for the current thread.  <a href="#e579f7b51f97fab7dfa2d3217b1ceaab"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#8ac8c2a3e5c8577704e6b76ac4ddbda4">peek</a> (<a class="el" href="logstring_8h.html#782e95610ad4dd24aee670f3b5846a3b">CFStringRef</a> &amp;dst)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Gets the current <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> value.  <a href="#8ac8c2a3e5c8577704e6b76ac4ddbda4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1_n_d_c.html#304eb43e2e4b5dd0a1024b8d06cc5121">pop</a> (<a class="el" href="logstring_8h.html#782e95610ad4dd24aee670f3b5846a3b">CFStringRef</a> &amp;dst)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Gets and removes the current <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> value.  <a href="#304eb43e2e4b5dd0a1024b8d06cc5121"></a><br></td></tr>
</table>
<hr><h2>Member Typedef Documentation</h2>
<a class="anchor" name="06fd35d312837c220d1781b630646621"></a><!-- doxytag: member="log4cxx::NDC::DiagnosticContext" ref="06fd35d312837c220d1781b630646621" args="" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">typedef std::pair&lt;<a class="el" href="namespacelog4cxx.html#d7ec98d27bca7666e23f27dd1fb181c8">LogString</a>, <a class="el" href="namespacelog4cxx.html#d7ec98d27bca7666e23f27dd1fb181c8">LogString</a>&gt; <a class="el" href="classlog4cxx_1_1_n_d_c.html#06fd35d312837c220d1781b630646621">DiagnosticContext</a>          </td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Pair of Message and FullMessage. 
<p>
    </td>
  </tr>
</table>
<a class="anchor" name="d27ab948303a389e8150ec1d837f1736"></a><!-- doxytag: member="log4cxx::NDC::Stack" ref="d27ab948303a389e8150ec1d837f1736" args="" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">typedef std::stack&lt;<a class="el" href="classlog4cxx_1_1_n_d_c.html#06fd35d312837c220d1781b630646621">DiagnosticContext</a>&gt; <a class="el" href="classlog4cxx_1_1_n_d_c.html#d27ab948303a389e8150ec1d837f1736">Stack</a>          </td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
    </td>
  </tr>
</table>
<hr><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" name="8ec640ca3549a71be17f9fff55d4b6b8"></a><!-- doxytag: member="log4cxx::NDC::NDC" ref="8ec640ca3549a71be17f9fff55d4b6b8" args="(const std::string &amp;message)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top"><a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a>           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">const std::string &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>message</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Creates a nested diagnostic context. 
<p>
Since java performs no automatic cleanup of objects when a scope is left, in log4j <a class="el" href="classlog4cxx_1_1_n_d_c.html#670a4077b7624737946c2a15817dfcee">push()</a> and <a class="el" href="classlog4cxx_1_1_n_d_c.html#300d98eecc81234f5ed86cfb3b41b548">pop()</a> must be used to manage the <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a>. For convenience, <a class="el" href="namespacelog4cxx.html">log4cxx</a> provides an <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> constructor and destructor which simply call the <a class="el" href="classlog4cxx_1_1_n_d_c.html#670a4077b7624737946c2a15817dfcee">push()</a> and <a class="el" href="classlog4cxx_1_1_n_d_c.html#300d98eecc81234f5ed86cfb3b41b548">pop()</a> methods, allowing for automatic cleanup when the current scope ends.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>message</em>&nbsp;</td><td>The new diagnostic context information. </td></tr>
  </table>
</dl>
<dl compact><dt><b>See also:</b></dt><dd>The <a class="el" href="classlog4cxx_1_1_n_d_c.html#670a4077b7624737946c2a15817dfcee">push</a> method. </dd></dl>
    </td>
  </tr>
</table>
<a class="anchor" name="7be25f4d39f960d05de41a18af9dabf1"></a><!-- doxytag: member="log4cxx::NDC::~NDC" ref="7be25f4d39f960d05de41a18af9dabf1" args="()" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">~<a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a>           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="mdname1" valign="top" nowrap>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Removes the topmost element from the <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> stack. 
<p>
<dl compact><dt><b>See also:</b></dt><dd>The <a class="el" href="classlog4cxx_1_1_n_d_c.html#300d98eecc81234f5ed86cfb3b41b548">pop</a> method. </dd></dl>
    </td>
  </tr>
</table>
<a class="anchor" name="8eac1aac9c4cc771421d583b886d2cb3"></a><!-- doxytag: member="log4cxx::NDC::NDC" ref="8eac1aac9c4cc771421d583b886d2cb3" args="(const std::wstring &amp;message)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top"><a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a>           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">const std::wstring &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>message</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Creates a nested diagnostic context. 
<p>
Since java performs no automatic cleanup of objects when a scope is left, in log4j <a class="el" href="classlog4cxx_1_1_n_d_c.html#670a4077b7624737946c2a15817dfcee">push()</a> and <a class="el" href="classlog4cxx_1_1_n_d_c.html#300d98eecc81234f5ed86cfb3b41b548">pop()</a> must be used to manage the <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a>. For convenience, <a class="el" href="namespacelog4cxx.html">log4cxx</a> provides an <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> constructor and destructor which simply call the <a class="el" href="classlog4cxx_1_1_n_d_c.html#670a4077b7624737946c2a15817dfcee">push()</a> and <a class="el" href="classlog4cxx_1_1_n_d_c.html#300d98eecc81234f5ed86cfb3b41b548">pop()</a> methods, allowing for automatic cleanup when the current scope ends.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>message</em>&nbsp;</td><td>The new diagnostic context information. </td></tr>
  </table>
</dl>
<dl compact><dt><b>See also:</b></dt><dd>The <a class="el" href="classlog4cxx_1_1_n_d_c.html#670a4077b7624737946c2a15817dfcee">push</a> method. </dd></dl>
    </td>
  </tr>
</table>
<a class="anchor" name="8a2cd4b0aa44ad594cfcb387751f197a"></a><!-- doxytag: member="log4cxx::NDC::NDC" ref="8a2cd4b0aa44ad594cfcb387751f197a" args="(const std::basic_string&lt; UniChar &gt; &amp;message)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top"><a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a>           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">const std::basic_string&lt; <a class="el" href="namespacelog4cxx.html#7edf438a3547255847b2b903b1a36aaf">UniChar</a> &gt; &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>message</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Creates a nested diagnostic context. 
<p>
Since java performs no automatic cleanup of objects when a scope is left, in log4j <a class="el" href="classlog4cxx_1_1_n_d_c.html#670a4077b7624737946c2a15817dfcee">push()</a> and <a class="el" href="classlog4cxx_1_1_n_d_c.html#300d98eecc81234f5ed86cfb3b41b548">pop()</a> must be used to manage the <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a>. For convenience, <a class="el" href="namespacelog4cxx.html">log4cxx</a> provides an <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> constructor and destructor which simply call the <a class="el" href="classlog4cxx_1_1_n_d_c.html#670a4077b7624737946c2a15817dfcee">push()</a> and <a class="el" href="classlog4cxx_1_1_n_d_c.html#300d98eecc81234f5ed86cfb3b41b548">pop()</a> methods, allowing for automatic cleanup when the current scope ends.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>message</em>&nbsp;</td><td>The new diagnostic context information. </td></tr>
  </table>
</dl>
<dl compact><dt><b>See also:</b></dt><dd>The <a class="el" href="classlog4cxx_1_1_n_d_c.html#670a4077b7624737946c2a15817dfcee">push</a> method. </dd></dl>
    </td>
  </tr>
</table>
<a class="anchor" name="4c14d449acdaeb48752b95840b3a7391"></a><!-- doxytag: member="log4cxx::NDC::NDC" ref="4c14d449acdaeb48752b95840b3a7391" args="(const CFStringRef &amp;message)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top"><a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a>           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">const <a class="el" href="logstring_8h.html#782e95610ad4dd24aee670f3b5846a3b">CFStringRef</a> &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>message</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Creates a nested diagnostic context. 
<p>
Since java performs no automatic cleanup of objects when a scope is left, in log4j <a class="el" href="classlog4cxx_1_1_n_d_c.html#670a4077b7624737946c2a15817dfcee">push()</a> and <a class="el" href="classlog4cxx_1_1_n_d_c.html#300d98eecc81234f5ed86cfb3b41b548">pop()</a> must be used to manage the <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a>. For convenience, <a class="el" href="namespacelog4cxx.html">log4cxx</a> provides an <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> constructor and destructor which simply call the <a class="el" href="classlog4cxx_1_1_n_d_c.html#670a4077b7624737946c2a15817dfcee">push()</a> and <a class="el" href="classlog4cxx_1_1_n_d_c.html#300d98eecc81234f5ed86cfb3b41b548">pop()</a> methods, allowing for automatic cleanup when the current scope ends.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>message</em>&nbsp;</td><td>The new diagnostic context information. </td></tr>
  </table>
</dl>
<dl compact><dt><b>See also:</b></dt><dd>The <a class="el" href="classlog4cxx_1_1_n_d_c.html#670a4077b7624737946c2a15817dfcee">push</a> method. </dd></dl>
    </td>
  </tr>
</table>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="14dabca7589b28dc6adca2c5367546e1"></a><!-- doxytag: member="log4cxx::NDC::clear" ref="14dabca7589b28dc6adca2c5367546e1" args="()" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static void clear           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="mdname1" valign="top" nowrap>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Clear any nested diagnostic information if any. 
<p>
This method is useful in cases where the same thread can be potentially used over and over in different unrelated contexts.     </td>
  </tr>
</table>
<a class="anchor" name="08f7cc8fa9fa9746b69f0bef73e07044"></a><!-- doxytag: member="log4cxx::NDC::cloneStack" ref="08f7cc8fa9fa9746b69f0bef73e07044" args="()" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static <a class="el" href="classlog4cxx_1_1_n_d_c.html#d27ab948303a389e8150ec1d837f1736">Stack</a>* cloneStack           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="mdname1" valign="top" nowrap>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Clone the diagnostic context for the current thread. 
<p>
Internally a diagnostic context is represented as a stack. A given thread can supply the stack (i.e. diagnostic context) to a child thread so that the child can inherit the parent thread's diagnostic context. <p>
The child thread uses the <a class="el" href="classlog4cxx_1_1_n_d_c.html#078b713ccf74bf2628b2230fbe597d41">inherit</a> method to inherit the parent's diagnostic context. <p>
If not passed to <a class="el" href="classlog4cxx_1_1_n_d_c.html#078b713ccf74bf2628b2230fbe597d41">inherit</a>, returned stack should be deleted by caller. <dl compact><dt><b>Returns:</b></dt><dd>Stack A clone of the current thread's diagnostic context, will not be null. </dd></dl>
    </td>
  </tr>
</table>
<a class="anchor" name="cb0b14918df8211fb25cb23bd0384d51"></a><!-- doxytag: member="log4cxx::NDC::empty" ref="cb0b14918df8211fb25cb23bd0384d51" args="()" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static bool empty           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="mdname1" valign="top" nowrap>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Tests if the <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> is empty. 
<p>
    </td>
  </tr>
</table>
<a class="anchor" name="ec930584769a8379ff4ee6ecd2448508"></a><!-- doxytag: member="log4cxx::NDC::get" ref="ec930584769a8379ff4ee6ecd2448508" args="(LogString &amp;dest)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static bool get           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top"><a class="el" href="namespacelog4cxx.html#d7ec98d27bca7666e23f27dd1fb181c8">LogString</a> &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>dest</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Get the current value of the <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> of the currrent thread. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>dest</em>&nbsp;</td><td>destination to which to append content of <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a>. </td></tr>
  </table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>true if <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> is set. </dd></dl>
    </td>
  </tr>
</table>
<a class="anchor" name="b275726b46a696f8b20c4a23113230d9"></a><!-- doxytag: member="log4cxx::NDC::getDepth" ref="b275726b46a696f8b20c4a23113230d9" args="()" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static int getDepth           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="mdname1" valign="top" nowrap>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Get the current nesting depth of this diagnostic context. 
<p>
    </td>
  </tr>
</table>
<a class="anchor" name="078b713ccf74bf2628b2230fbe597d41"></a><!-- doxytag: member="log4cxx::NDC::inherit" ref="078b713ccf74bf2628b2230fbe597d41" args="(Stack *stack)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static void inherit           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top"><a class="el" href="classlog4cxx_1_1_n_d_c.html#d27ab948303a389e8150ec1d837f1736">Stack</a> *&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>stack</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Inherit the diagnostic context of another thread. 
<p>
The parent thread can obtain a reference to its diagnostic context using the <a class="el" href="classlog4cxx_1_1_n_d_c.html#08f7cc8fa9fa9746b69f0bef73e07044">cloneStack</a> method. It should communicate this information to its child so that it may inherit the parent's diagnostic context. <p>
The parent's diagnostic context is cloned before being inherited. In other words, once inherited, the two diagnostic contexts can be managed independently. <dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>stack</em>&nbsp;</td><td>The diagnostic context of the parent thread, will be deleted during call. If NULL, <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> will not be modified. </td></tr>
  </table>
</dl>
    </td>
  </tr>
</table>
<a class="anchor" name="8ac8c2a3e5c8577704e6b76ac4ddbda4"></a><!-- doxytag: member="log4cxx::NDC::peek" ref="8ac8c2a3e5c8577704e6b76ac4ddbda4" args="(CFStringRef &amp;dst)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static bool peek           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top"><a class="el" href="logstring_8h.html#782e95610ad4dd24aee670f3b5846a3b">CFStringRef</a> &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>dst</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Gets the current <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> value. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>dst</em>&nbsp;</td><td>destination. </td></tr>
  </table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>true if <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> value set. </dd></dl>
    </td>
  </tr>
</table>
<a class="anchor" name="64259a85df3a8f1e3b00d5c71bc808ff"></a><!-- doxytag: member="log4cxx::NDC::peek" ref="64259a85df3a8f1e3b00d5c71bc808ff" args="(std::basic_string&lt; UniChar &gt; &amp;dst)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static bool peek           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">std::basic_string&lt; <a class="el" href="namespacelog4cxx.html#7edf438a3547255847b2b903b1a36aaf">UniChar</a> &gt; &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>dst</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Appends the current <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> content to the provided string. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>dst</em>&nbsp;</td><td>destination. </td></tr>
  </table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>true if <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> value set. </dd></dl>
    </td>
  </tr>
</table>
<a class="anchor" name="a7420cde96c577e4c6a08354c7725ebd"></a><!-- doxytag: member="log4cxx::NDC::peek" ref="a7420cde96c577e4c6a08354c7725ebd" args="(std::wstring &amp;dst)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static bool peek           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">std::wstring &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>dst</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Appends the current <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> content to the provided string. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>dst</em>&nbsp;</td><td>destination. </td></tr>
  </table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>true if <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> value set. </dd></dl>
    </td>
  </tr>
</table>
<a class="anchor" name="ca6fa7a1575b839b4f8ac9a60ec6c2d1"></a><!-- doxytag: member="log4cxx::NDC::peek" ref="ca6fa7a1575b839b4f8ac9a60ec6c2d1" args="(std::string &amp;buf)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static bool peek           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">std::string &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>buf</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Get top value without removing value. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>buf</em>&nbsp;</td><td>to which top value is appended. </td></tr>
  </table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>true if <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> contained at least one value. </dd></dl>
    </td>
  </tr>
</table>
<a class="anchor" name="79fee8d99de96898fbe985d692b5cfe1"></a><!-- doxytag: member="log4cxx::NDC::peek" ref="79fee8d99de96898fbe985d692b5cfe1" args="()" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static <a class="el" href="namespacelog4cxx.html#d7ec98d27bca7666e23f27dd1fb181c8">LogString</a> peek           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="mdname1" valign="top" nowrap>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Looks at the last diagnostic context at the top of this <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> without removing it. 
<p>
The returned value is the value that was pushed last. If no context is available, then the empty string "" is returned. <dl compact><dt><b>Returns:</b></dt><dd>String The innermost diagnostic context. </dd></dl>
    </td>
  </tr>
</table>
<a class="anchor" name="304eb43e2e4b5dd0a1024b8d06cc5121"></a><!-- doxytag: member="log4cxx::NDC::pop" ref="304eb43e2e4b5dd0a1024b8d06cc5121" args="(CFStringRef &amp;dst)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static bool pop           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top"><a class="el" href="logstring_8h.html#782e95610ad4dd24aee670f3b5846a3b">CFStringRef</a> &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>dst</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Gets and removes the current <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> value. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>dst</em>&nbsp;</td><td>destination. </td></tr>
  </table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>true if <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> value set. </dd></dl>
    </td>
  </tr>
</table>
<a class="anchor" name="c71838e8767dd3c956b3f4774d945d5f"></a><!-- doxytag: member="log4cxx::NDC::pop" ref="c71838e8767dd3c956b3f4774d945d5f" args="(std::basic_string&lt; UniChar &gt; &amp;dst)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static bool pop           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">std::basic_string&lt; <a class="el" href="namespacelog4cxx.html#7edf438a3547255847b2b903b1a36aaf">UniChar</a> &gt; &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>dst</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Appends the current <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> content to the provided string and removes the value from the <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a>. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>dst</em>&nbsp;</td><td>destination. </td></tr>
  </table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>true if <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> value set. </dd></dl>
    </td>
  </tr>
</table>
<a class="anchor" name="2667d6cbcbc31976468db35bf2e24778"></a><!-- doxytag: member="log4cxx::NDC::pop" ref="2667d6cbcbc31976468db35bf2e24778" args="(std::wstring &amp;dst)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static bool pop           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">std::wstring &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>dst</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Appends the current <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> content to the provided string and removes the value from the <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a>. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>dst</em>&nbsp;</td><td>destination. </td></tr>
  </table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>true if <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> value set. </dd></dl>
    </td>
  </tr>
</table>
<a class="anchor" name="3d0d9f6e0412585ec1e9b372f9bac6b0"></a><!-- doxytag: member="log4cxx::NDC::pop" ref="3d0d9f6e0412585ec1e9b372f9bac6b0" args="(std::string &amp;buf)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static bool pop           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">std::string &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>buf</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Pop top value off stack. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>buf</em>&nbsp;</td><td>to which top value is appended. </td></tr>
  </table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>true if <a class="el" href="classlog4cxx_1_1_n_d_c.html">NDC</a> contained at least one value. </dd></dl>
    </td>
  </tr>
</table>
<a class="anchor" name="300d98eecc81234f5ed86cfb3b41b548"></a><!-- doxytag: member="log4cxx::NDC::pop" ref="300d98eecc81234f5ed86cfb3b41b548" args="()" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static <a class="el" href="namespacelog4cxx.html#d7ec98d27bca7666e23f27dd1fb181c8">LogString</a> pop           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="mdname1" valign="top" nowrap>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Pop top value off stack. 
<p>
<dl compact><dt><b>Returns:</b></dt><dd>top value. </dd></dl>
    </td>
  </tr>
</table>
<a class="anchor" name="e579f7b51f97fab7dfa2d3217b1ceaab"></a><!-- doxytag: member="log4cxx::NDC::push" ref="e579f7b51f97fab7dfa2d3217b1ceaab" args="(const CFStringRef &amp;message)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static void push           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">const <a class="el" href="logstring_8h.html#782e95610ad4dd24aee670f3b5846a3b">CFStringRef</a> &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>message</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Push new diagnostic context information for the current thread. 
<p>
The contents of the <code>message</code> parameter is determined solely by the client. <dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>message</em>&nbsp;</td><td>The new diagnostic context information. </td></tr>
  </table>
</dl>
    </td>
  </tr>
</table>
<a class="anchor" name="67f283cbdbf951781c6f24f93b000fa1"></a><!-- doxytag: member="log4cxx::NDC::push" ref="67f283cbdbf951781c6f24f93b000fa1" args="(const std::basic_string&lt; UniChar &gt; &amp;message)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static void push           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">const std::basic_string&lt; <a class="el" href="namespacelog4cxx.html#7edf438a3547255847b2b903b1a36aaf">UniChar</a> &gt; &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>message</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Push new diagnostic context information for the current thread. 
<p>
The contents of the <code>message</code> parameter is determined solely by the client. <dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>message</em>&nbsp;</td><td>The new diagnostic context information. </td></tr>
  </table>
</dl>
    </td>
  </tr>
</table>
<a class="anchor" name="ccac902acd908c0dff6601c7a861785e"></a><!-- doxytag: member="log4cxx::NDC::push" ref="ccac902acd908c0dff6601c7a861785e" args="(const std::wstring &amp;message)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static void push           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">const std::wstring &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>message</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Push new diagnostic context information for the current thread. 
<p>
The contents of the <code>message</code> parameter is determined solely by the client. <dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>message</em>&nbsp;</td><td>The new diagnostic context information. </td></tr>
  </table>
</dl>
    </td>
  </tr>
</table>
<a class="anchor" name="670a4077b7624737946c2a15817dfcee"></a><!-- doxytag: member="log4cxx::NDC::push" ref="670a4077b7624737946c2a15817dfcee" args="(const std::string &amp;message)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static void push           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">const std::string &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>message</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Push new diagnostic context information for the current thread. 
<p>
The contents of the <code>message</code> parameter is determined solely by the client. <dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>message</em>&nbsp;</td><td>The new diagnostic context information. </td></tr>
  </table>
</dl>
    </td>
  </tr>
</table>
<a class="anchor" name="db03ca6083676de6be2adf9346f12a89"></a><!-- doxytag: member="log4cxx::NDC::pushLS" ref="db03ca6083676de6be2adf9346f12a89" args="(const LogString &amp;message)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static void pushLS           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">const <a class="el" href="namespacelog4cxx.html#d7ec98d27bca7666e23f27dd1fb181c8">LogString</a> &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>message</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Push new diagnostic context information for the current thread. 
<p>
The contents of the <code>message</code> parameter is determined solely by the client. <dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>message</em>&nbsp;</td><td>The new diagnostic context information. </td></tr>
  </table>
</dl>
    </td>
  </tr>
</table>
<a class="anchor" name="f54fd13c5dd6e2cd20190d8ce7b3125d"></a><!-- doxytag: member="log4cxx::NDC::remove" ref="f54fd13c5dd6e2cd20190d8ce7b3125d" args="()" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">static void remove           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="mdname1" valign="top" nowrap>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [static]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Remove the diagnostic context for this thread. 
<p>
Each thread that created a diagnostic context by calling <a class="el" href="classlog4cxx_1_1_n_d_c.html#670a4077b7624737946c2a15817dfcee">push</a> should call this method before exiting. Otherwise, the memory used by the <b>thread</b> cannot be reclaimed by the VM. <p>
As this is such an important problem in heavy duty systems and because it is difficult to always guarantee that the remove method is called before exiting a thread, this method has been augmented to lazily remove references to dead threads. In practice, this means that you can be a little sloppy and occasionally forget to call <a class="el" href="classlog4cxx_1_1_n_d_c.html#f54fd13c5dd6e2cd20190d8ce7b3125d">remove</a> before exiting a thread. However, you must call <code>remove</code> sometime. If you never call it, then your application is sure to run out of memory.     </td>
  </tr>
</table>
<hr>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="ndc_8h.html">ndc.h</a></ul>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements.  See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License.  You may obtain a copy of the License at

     http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
    </BODY>
</HTML>