Summary
NoInheritedAttribute can be applied to class type to prevent inherited from ancestor members from been serialized.
Syntax
NoInheritedAttribute = class(TSerlnAttr);
Remarks
Generally, NoInheritedAttribute should be used if a class descends from another class which is not intended to be serializable. In this case base class usually contains many members which should not be serialized and usually cannot, because of unsupported member types. Applying NoInheritedAttribute will specify that all directly and indirectly inherited members should be excluded from serialized members set.
Examples
Delphi | Copy Code |
---|---|
[NoInherited] TCustomer = class(TComponent) public Name: string; Address: string; end; |