zjf
2023-03-06 392b76515f40376b6d36f40a114850ef63650384
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
/////////////////////////////////////////////////////////////////////////////// 
// Copyright (C) 2002-2016, Open Design Alliance (the "Alliance"). 
// All rights reserved. 
// 
// This software and its documentation and related materials are owned by 
// the Alliance. The software may only be incorporated into application 
// programs owned by members of the Alliance, subject to a signed 
// Membership Agreement and Supplemental Software License Agreement with the
// Alliance. The structure and organization of this software are the valuable  
// trade secrets of the Alliance and its suppliers. The software is also 
// protected by copyright law and international treaty provisions. Application  
// programs incorporating this software must include the following statement 
// with their copyright notices:
//   
//   This application incorporates Teigha(R) software pursuant to a license 
//   agreement with Open Design Alliance.
//   Teigha(R) Copyright (C) 2002-2016 by Open Design Alliance. 
//   All rights reserved.
//
// By use of this software, its documentation or related materials, you 
// acknowledge and accept the above terms.
///////////////////////////////////////////////////////////////////////////////
 
 
 
 
#ifndef _ODDBLAYERTABLETABLERECORD_INCLUDED
#define _ODDBLAYERTABLETABLERECORD_INCLUDED
 
#include "TD_PackPush.h"
 
#include "DbSymbolTableRecord.h"
#include "CmColor.h"
 
class OdDbLayerTable;
 
/** \details
  <group OdDb_Classes>
 
  This class implements the /layer record/ object, which represents a layer in the database. 
  This class inherits the base functionality of named records. 
 
  \sa
  TD_Db
    
  \sa
  <link db_layer_sample_table.html, Example of Working with the Layer Table Object>
 
  <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
  \sa
  <link db_layer.html, Working with Layers>
 
  OdDbLayerTable class
*/
class TOOLKIT_EXPORT OdDbLayerTableRecord : public OdDbSymbolTableRecord
{
public:
  ODDB_DECLARE_MEMBERS(OdDbLayerTableRecord);
 
  /** \details
    Builds an instance of the /layer record/ object.
    
    \remarks
    Use the static pseudo-constructor instead it.
    See: <link db_layer_add_name.html, Adding and Naming Layers>
  */
  OdDbLayerTableRecord();
 
  typedef OdDbLayerTable TableType;
 
 
  /** \details
    Determines whether the /layer record/ object is invisible and accessible for regenerating, 
    printing, selecting, and editing (DXF 70, bit 0x01) and returns True if the layer is frozen 
    or False if the layer is thawed.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_status.html, Status of Layers>
 
    OdDbLayerTableRecord::setIsFrozen() method
  */
  bool isFrozen() const;
 
 
  /** \details
    Sets the Freeze status as a Boolean value (DXF 70, bit 0x01). The initial value is False 
    (Thawed) by default.
 
    \param bStatus [in]  True - to freeze the layer, or False - to thaw the layer.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_status.html, Status of Layers>
 
    OdDbLayerTableRecord::isFrozen() method
  */
  void setIsFrozen( bool bStatus );
 
 
  /** \details
    Determines whether the /layer record/ object is invisible (DXF 62, negative is off, positive 
    is on) and returns True if the layer is off (invisible) or False if the layer is on (visible).
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_status.html, Status of Layers>
 
    OdDbLayerTableRecord::setIsOff() method
  */
  bool isOff() const;
 
 
  /** \details
    Sets the On-Off status as a Boolean value (DXF 62). The initial value is False (Visible) by 
    default.
 
    \param bStatus [in]  True - to make the layer invisible (off), or False - to make the layer visible (on).
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_status.html, Status of Layers>
 
    OdDbLayerTableRecord::isOff() method
  */
  void setIsOff( bool bStatus );
 
 
  /** \details
    Returns true if and only if the layer is frozen in new viewports (DXF 70, bit 0x02).
 
    \sa
    OdDbLayerTableRecord::setVPDFLT() method
  */
  bool VPDFLT() const;
 
 
  /** \details
    Sets the Freeze status in new viewports for the layer as a Boolean value (DXF 70, bit 0x02).
 
    \param bStatus [in]  True - to specify the frozen layers for new viewports, or 
                False - to specify the thawed layers for new viewports.
 
    \sa
    OdDbLayerTableRecord::VPDFLT() method
  */
  void setVPDFLT( bool bStatus );
 
 
  /** \details
    Determines whether the /layer record/ object is accessible for selecting and editing 
    (DXF 70, bit 0x04) and returns True if the layer is locked or False if the layer is editable.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_status.html, Status of Layers>
 
    OdDbLayerTableRecord::setIsLocked() method
  */
  bool isLocked() const;
 
 
  /** \details
    Sets the Lock status as a Boolean value (DXF 70, bit 0x04). The initial value is False 
    (Editable) by default.
 
    \param bStatus [in]  True - to lock the layer, or False - to unlock the layer.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_status.html, Status of Layers>
 
    OdDbLayerTableRecord::isLocked() method
  */
  void setIsLocked( bool bStatus );
 
 
  /** \details
    Determines whether the /layer record/ object is accessible for printing (DXF 290) and 
    returns True if the layer is plottable or False if the layer is unplottable.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_status.html, Status of Layers>
 
    OdDbLayerTableRecord::setIsPlottable() method
  */
  bool isPlottable() const;
 
 
  /** \details
    Sets the Plot status as a Boolean value (DXF 290). The initial value is True (Plottable) 
    by default.
 
    \param bStatus [in]  True - to make the layer plottable, or False - to make the layer no plottable.
 
    \remarks
    Some layers cannot be set to plottable; e.g., the "Defpoints" Layer.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_status.html, Status of Layers>
 
    OdDbLayerTableRecord::isPlottable() method
  */
  void setIsPlottable( bool bStatus );
 
 
  /** \details
    Determines whether the /layer record/ object is displayed for the host application and 
    returns True if the layer is hidden or False if the layer is shown.
 
    \remarks
    The static isHidden() method checks the Hidden status for the specified layer ID.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_status.html, Status of Layers>
 
    OdDbLayerTableRecord::setIsHidden() method
  */
  bool isHidden() const;
  static bool isHidden( const OdDbObjectId& idLayer );
 
 
  /** \details
    Sets the Hidden status as a Boolean value. The initial value is False (Shown) by default.
 
    \param bStatus [in]  True - to hide the layer, or False - to show the layer.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_status.html, Status of Layers>
 
    OdDbLayerTableRecord::isHidden() method
  */
  void setIsHidden( bool bStatus );
 
 
  /** \details
    Determines whether the /layer record/ object is reconciled with another object and returns 
    True if the layer is reconciled, or False if the layer is not reconciled.
 
    \remarks
    The static isReconciled() method checks the Reconcile status for the specified layer ID.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_status.html, Status of Layers>
 
    OdDbLayerTableRecord::setIsReconciled() method
  */
  bool isReconciled() const;
  static bool isReconciled( const OdDbObjectId& idLayer );
 
 
  /** \details
    Sets the Reconcile status as a Boolean value.
 
    \param bStatus [in]  True - to set the Reconcile status, or False - to clear the Reconcile status.
 
    \sa
    <link db_layer_status.html, Status of Layers>
 
    OdDbLayerTableRecord::isReconciled() method
  */
  void setIsReconciled( bool bStatus = true );
 
 
  /** \details
    Returns the transparency for the /layer record/ object (as XData). This transparency is 
    used when the Transparency property of an entity belonged to the layer is set to the byLayer 
    value. The actual transparency value can depend on the viewport in which the entity is rendered.
 
    \param idViewport  [in] Object ID of the viewport for which the transparency value should be obtained.
    \param pIsOverride [out] Pointer to the Boolean variable in which this method saves the result:  
                    True if it is the specific transparency previously specified for the viewport, or   
                    False if it is own transparency and the layer does not store a transparency for 
                    the specified viewport.
 
    \remarks
    The same layer can have different transparencies in different viewports. Therefore this method 
    is overdriven. The method without arguments returns the own transparency of the layer. The method 
    with two arguments returns the specific transparency specified for the viewport or own transparency 
    if the specific transparency is not specified for the viewport.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_properties.html, Specific Properties of Layers>
 
    OdDbLayerTableRecord::setTransparency() method
  */
  OdCmTransparency transparency() const;
  OdCmTransparency transparency( const OdDbObjectId& idViewport, bool* pIsOverride = 0 ) const;
 
 
  /** \details
    Sets the transparency for the /layer record/ object (as XData) and returns eOk if successful. 
    This transparency is used when the Transparency property of an entity belonged to this layer 
    is set to byLayer value. The initial value is byAlpha = 100% value (solid) by default. The same 
    entity can be rendered using different transparencies in different viewports.
 
    \param cmTransparency [in]  Reference to the transparency instance to be set as an Alpha-value in 
                       range 1 to 255.
    \param idViewport     [in] Object ID of the viewport in which the layer must have the specific transparency.
 
    \remarks
    The same layer can have different transparencies in different viewports. Therefore this method 
    is overdriven. The method with one argument sets the own transparency of the layer. The method 
    with two arguments sets the specific transparency for the viewport.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_properties.html, Specific Properties of Layers>
 
    <link cm.html, Colors and Transparencies>
 
    OdDbLayerTableRecord::transparency() method
  */
  OdResult setTransparency( const OdCmTransparency& cmTransparency );
  void setTransparency( const OdCmTransparency& cmTransparency, const OdDbObjectId& idViewport );
 
 
  /** \details
    Returns the color for the /layer record/ object (DXF 62). This color is used when 
    the Color property of an entity belonged to the layer is set to byLayer value. The actual 
    color value can depend on the viewport in which the entity is rendered.
 
    \param idViewport  [in] Object ID of the viewport for which the color value should be obtained.
    \param pIsOverride [out] Pointer to the Boolean variable in which this method saves the result:
                    True if it is the specific color previously specified for the viewport, or 
                    False if it is own color and the layer does not store a color for the 
                    specified viewport.
 
    \remarks
    The same layer can have different colors in different viewports. Therefore this method is 
    overdriven. The method without arguments returns the own color of the layer. The method 
    with two arguments returns the specific color specified for the viewport or own color 
    if the specific color is not specified for the viewport.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_properties.html, Specific Properties of Layers>
 
    OdDbLayerTableRecord::setColor() method
  */
  OdCmColor color() const;
  OdCmColor color( const OdDbObjectId& viewportId, bool* pIsOverride = 0 ) const;
 
 
  /** \details
    Sets the color for the /layer record/ object (DXF 62). This color is used when the 
    Color property of an entity belonged to this layer is set to byLayer value. The initial 
    value is Foreground (index 7) by default. The same entity can be rendered using different 
    colors in different viewports.
 
    \param cmColor    [in] Reference to the color instance to be set.
    \param idViewport [in] Object ID of the viewport in which the layer must have the specific color.
 
    \remarks
    The same layer can have different colors in different viewports. Therefore this method is 
    overdriven. The method with one argument sets the own color of the layer. The method with 
    two arguments sets the specific color for the viewport.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_properties.html, Specific Properties of Layers>
 
    <link cm.html, Colors and Transparencies>
 
    OdDbLayerTableRecord::color() method
  */
  void setColor( const OdCmColor& cmColor );
  void setColor( const OdCmColor& cmColor, const OdDbObjectId& idViewport );
 
  
  /** \details
    Returns the color index for the /layer record/ object (DXF 62). When the color method is 
    set to byColor, this method returns an equivalent color index.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_properties.html, Specific Properties of Layers>
 
    OdDbLayerTableRecord::setColorIndex() method
  */
  OdInt16 colorIndex() const;
 
 
  /** \details
    Sets the color index for the /layer record/ object (DXF 62) as an Integer value. The initial   
    value is 7 (Foreground) by default.
 
    \param idxColor [in]  Color index in range 1 to 255.
 
    \remarks
    When the index outs the range 1 to 255, this method generates an exception. This method sets  
    the color method to byACI.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_properties.html, Specific Properties of Layers>
 
    OdDbLayerTableRecord::colorIndex() method
  */
  void setColorIndex( OdInt16 idxColor );
 
 
  /** \details
    Returns the lineweight of the /layer record/ object (DXF 370). This lineweight is used when  
    the Lineweight property of an entity belonged to this layer is set to ByLayer value. The actual 
    lineweight can depend on the viewport in which the entity is rendered.
 
    \param idViewport  [in] Object ID of the viewport for which the lineweight should be obtained.
    \param pIsOverride [out] Pointer to the Boolean variable in which this method saves the result:
                    True if it is the specific lineweight previously specified for the viewport, or 
                    False if it is own lineweight and the layer does not store a lineweight for the 
                    specified viewport.
 
    \remarks
    The same layer can have different lineweights in different viewports. Therefore this method is 
    overdriven. The method without arguments returns the own lineweight of the layer. The method with 
    two arguments returns the specific lineweight specified for the viewport or own lineweight if the 
    specific lineweight is not specified for the viewport.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_properties.html, Specific Properties of Layers>
 
    OdDbLayerTableRecord::setLineWeight() method
  */
  OdDb::LineWeight lineWeight() const;
  OdDb::LineWeight lineWeight( const OdDbObjectId& idViewport, bool* pIsOverride = 0 ) const;
 
 
  /** \details
    Sets the lineweight for the /layer record/ object (DXF 370). This lineweight is used when the 
    Lineweight property of an entity belonged to this layer is set to ByLayer value. The initial value 
    is kLnWtByLwDefault by default. The same entity can be rendered using different lineweights in 
    different viewports.
 
    \param kLnWtEnum  [in] Lineweight (value of the enumerator).
    \param idViewport [in] Object ID of the viewport in which the layer must have the specific lineweight.
 
    \remarks
    The same layer can have different lineweights in different viewports. Therefore this method is 
    overdriven. The method with one argument sets the own lineweight of the layer. The method with 
    two arguments sets the specific lineweight for the viewport.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_properties.html, Specific Properties of Layers>
 
    OdDbLayerTableRecord::lineWeight() method
  */
  void setLineWeight( OdDb::LineWeight kLnWtEnum );
  void setLineWeight( OdDb::LineWeight kLnWtEnum, const OdDbObjectId& idViewport );
 
 
  /** \details
    Returns the ID of the /linetype record/ object associated with the /layer record/ object 
    (DXF 6), or OdDb::kNULL when the layer is not associated with linetype. This linetype is 
    used when the Linetype property of an entity belonged to this layer is set to ByLayer value. 
    The actual linetype can depend on the viewport in which the entity is rendered.
 
    \param idViewport  [in] Object ID of the viewport for which the linetype ID should be obtained.
    \param pIsOverride [out] Pointer to the Boolean variable in which this method saves the result:
                    True if it is the specific linetype previously specified for the viewport, or 
                    False if it is own linetype and the layer does not store a linetype for the 
                    specified viewport.
 
    \remarks
    The same layer can have different linetypes in different viewports. Therefore this method is 
    overdriven. The method without arguments returns the own linetype of the layer. The method with 
    two arguments returns the specific linetype specified for the viewport or own linetype if the 
    specific linetype is not specified for the viewport.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_properties.html, Specific Properties of Layers>
 
    OdDbLayerTableRecord::setLinetypeObjectId() method
  */
  OdDbObjectId linetypeObjectId() const;
  OdDbObjectId linetypeObjectId( const OdDbObjectId& idViewport, bool* pIsOverride = 0 ) const;
 
 
  /** \details
    Sets the ID of the linetype record object for the layer record object (DXF 6) as an 
    ObDbObjectId instance. This method associates layer and linetype. This linetype is used when 
    the Linetype property of an entity belonged to this layer is set to ByLayer value. The initial 
    value associates the layer with the "Continuous" linetype by default. The same entity can be 
    rendered using different linetypes in different viewports.
 
    \param idLinetype [in]  Object ID of the linetype record object to associate it with the layer,
                   or OdDb::kNull to disassociate the layer and linetype.
    \param idViewport [in] Object ID of the viewport in which the layer must have the specific linetype.
 
    \remarks
    The same layer can have different linetypes in different viewports. Therefore this method is 
    overdriven. The method with one argument sets the own linetype of the layer. The method with two 
    arguments sets the specific linetype for the viewport.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_properties.html, Specific Properties of Layers>
 
    OdDbLayerTableRecord::linetypeObjectId() method
  */
  void setLinetypeObjectId( OdDbObjectId idLinetype );
  void setLinetypeObjectId( const OdDbObjectId& idLinetype, const OdDbObjectId& idViewport );
 
 
  /** \details
    Returns the ID of the material object associated with the /layer record/ object (DXF 347) 
    or OdDb::kNULL when the layer is not associated with material. This material is used when 
    the Material property of an entity belonged to this layer is set to ByLayer value.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_properties.html, Specific Properties of Layers>
 
    OdDbLayerTableRecord::setMaterialId() method
  */
  OdDbObjectId materialId() const;
 
 
  /** \details
    Sets the ID of the material object for the /layer record/ object (DXF 347) as an ObDbObjectId 
    instance. This method associates layer and material. The initial value associates the layer with 
    the "Global" material by default.
 
    \param idMaterial [in]  Object ID of the material object to associate it with the layer, 
                   or OdDb::kNull to disassociate the layer and material.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_properties.html, Specific Properties of Layers>
 
    OdDbLayerTableRecord::materialId() method
  */
  void setMaterialId( OdDbObjectId idMaterial );
 
 
  /** \details
    Retuns the name of the plot style associated with the /layer record/ object (DXF 390). This plot 
    style is used when the PlotStyle property of an entity belonged to this layer is set to ByLayer 
    value. The actual plot style can depend on the viewport in which the entity is rendered.
 
 
    \param idViewport  [in] Object ID of the viewport for which the plot style ID should be obtained.
    \param pIsOverride [out] Pointer to the Boolean variable in which this method saves the result:
                    True if it is the specific plot style previously specified for the viewport, or 
                    False if it is own plot style and the layer does not store a plot style for the 
                    specified viewport.
 
    \sa
    <link db_layer_properties.html, Specific Properties of Layers>
 
    OdDbLayerTableRecord::plotStyleNameId(), OdDbLayerTableRecord::setPlotStyleName() methods
  */
  OdString plotStyleName() const;
  OdString plotStyleName( const OdDbObjectId& idViewport, bool* pIsOverride = 0 ) const;
 
 
  /** \details
    Returns the ID of the /plot style/ object associated with the /layer record/ object (DXF 390) or 
    OdDb::kNULL when the layer is not associated with plot style. This plot style is used when the 
    PlotStyle property of an entity belonged to this layer is set to ByLayer value. The actual plot  
    style can depend on the viewport in which the entity is rendered.
 
    \param idViewport  [in] Object ID of the viewport for which the plot style ID should be obtained.
    \param pIsOverride [out] Pointer to the Boolean variable in which this method saves the result:
                    True if it is the specific plot style previously specified for the viewport, or 
                    False if it is own plot style and the layer does not store a plot style for the 
                    specified viewport.
 
    \sa
    <link db_layer_properties.html, Specific Properties of Layers>
 
    OdDbLayerTableRecord::plotStyleName(), OdDbLayerTableRecord::setPlotStyleName() methods
  */
  OdDbObjectId plotStyleNameId() const;
  OdDbObjectId plotStyleNameId( const OdDbObjectId& idViewport, bool* pIsOverride = 0 ) const;
 
 
  /** \details
    Sets the name or ID of the /place holder/ object for the /layer record/ object (DXF 390). This 
    method associates layer and plot style. The ID is an ObDbObjectId instance, the name is an 
    OdString instance. This plot style is used when the PlotStyle property of an entity belonged to 
    this layer is set to ByLayer value. The same entity can be rendered using different plot styles 
    in different viewports.
 
    \param sPlotStyleName [in]  Plot style name as non-empty string.
    \param idPlotStyle    [in] Object ID of the /place holder/ object to associate it with the layer,
                       or OdDb::kNull to disassociate the layer and plot style.
    \param idViewport     [in] Object ID of the viewport in which the layer must have the specific plot style.
 
    \remarks
    The same layer can have different plot styles in different viewports. Therefore this method is 
    overdriven. The method with one argument sets the own plot style of the layer using the plot style 
    name or plot style ID. The method with two arguments sets the specific plot style for the viewport 
    using the plot style name or plot style ID.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_properties.html, Specific Properties of Layers>
    
    <link OdDbPlaceHolder, OdDbPlaceHolder class>
    
    <link !!OVERLOADED_plotStyleName_OdDbLayerTableRecord, OdDbLayerTableRecord::plotStyleName()>, <link !!OVERLOADED_plotStyleNameId_OdDbLayerTableRecord, OdDbLayerTableRecord::plotStyleNameId()> methods
  */
  OdResult setPlotStyleName( const OdString& sPlotStyleName );
  void setPlotStyleName( const OdString& sPlotStyleName, const OdDbObjectId& idViewport);
  void setPlotStyleName( OdDbObjectId idPlotStyle );
  void setPlotStyleName( const OdDbObjectId& idPlotStyle, const OdDbObjectId& idViewport);
 
  
  /** \details
    Returns the description for the /layer record/ object.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_properties.html, Specific Properties of Layers>
 
    OdDbLayerTableRecord::setDescription() method
  */
  OdString description() const;
 
 
  /** \details
    Sets the description for the /layer record/ object as a String value up to 255 letters length. 
    The initial value is an empty string.
 
    \param sDescription [in]  Description as a String value.
    
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_properties.html, Specific Properties of Layers>
 
    OdDbLayerTableRecord::description() method
  */
  void setDescription( const OdString& sDescription );
 
 
  /** \details
    Determines whether the /layer record/ object is in-use when the generateUsageData() method  
    is called and returns True if the layer is in-use, or False if the layer is not use.
    
    \remarks
    Returns True when the generateUsageData() of the /layer table/ object has not been called
    or this /layer record/ object is not database resident.
 
    \sa
    <link db_layer_sample_record.html, Example of Working with the Layer Record Object>
 
    \sa
    <link db_layer_status.html, Status of Layers>
 
    OdDbLayerTable::generateUsageData() method
  */
  bool isInUse() const;
 
 
  virtual OdResult dwgInFields( OdDbDwgFiler* pFiler );
 
  virtual void dwgOutFields( OdDbDwgFiler* pFiler ) const;
 
  virtual OdResult dxfInFields( OdDbDxfFiler* pFiler );
 
  virtual void dxfOutFields( OdDbDxfFiler* pFiler ) const;
 
  virtual OdResult dxfInFields_R12( OdDbDxfFiler* pFiler );
 
  virtual void dxfOutFields_R12( OdDbDxfFiler* pFiler ) const;
 
  virtual OdResult subGetClassID( void* pClsid ) const;
 
  virtual OdResult subErase( bool erasing );
 
  virtual OdUInt32 subSetAttributes( OdGiDrawableTraits* pTraits ) const;
 
  virtual bool subWorldDraw( OdGiWorldDraw* pWd ) const;
 
  virtual void subViewportDraw( OdGiViewportDraw* pVd ) const;
 
  OdGiDrawable* drawable();
 
  void removeAllOverrides();
 
  void removeColorOverride( const OdDbObjectId& idViewport );
 
  void removeLinetypeOverride( const OdDbObjectId& idViewport );
 
  void removeLineWeightOverride( const OdDbObjectId& idViewport );
 
  void removePlotStyleOverride( const OdDbObjectId& idViewport );
 
  void removeTransparencyOverride( const OdDbObjectId& idViewport );
 
  void removeViewportOverrides( const OdDbObjectId& idViewport );
 
  bool hasOverrides( const OdDbObjectId& idViewport ) const;
 
  bool hasAnyOverrides() const;
};
 
/** \details
  The typified smart pointer for the /layer record/ object. This template class is 
  specialization of the OdSmartPtr class for the OdDbLayerTableRecord object.
 
  \sa
  <link smart_pointers.html, Working with Smart Pointers>
*/
typedef OdSmartPtr<OdDbLayerTableRecord> OdDbLayerTableRecordPtr;
 
#include "TD_PackPop.h"
 
#endif // _ODDBLAYERTABLETABLERECORD_INCLUDED