Maps class members to CSV fields.
- Namespace
- CsvHelper
.Configuration - Base Types
-
- object
- ClassMap
- Derived Types
graph BT
Type-->Base0["ClassMap"]
click Base0 "/CsvHelper/api/CsvHelper.Configuration/ClassMap"
Base0-->Base1["object"]
Type["ClassMap<TClass>"]
class Type type-node
Derived0["DefaultClassMap<T>"]-->Type
click Derived0 "/CsvHelper/api/CsvHelper.Configuration/DefaultClassMap_1"
Syntax
public abstract class ClassMap<TClass> : ClassMap
Type Parameters
| Name | Description |
|---|---|
| TClass | The System.Type of class to map. |
Constructors
| Name | Summary |
|---|---|
| ClassMap |
Creates an instance of ClassMap<TClass>.
|
Properties
| Name | Property Type | Summary |
|---|---|---|
| ClassType | Type |
The type of the class this map is for.
Inherited from ClassMap
|
| MemberMaps | MemberMapCollection |
The class member mappings.
Inherited from ClassMap
|
| ParameterMaps | List |
The class constructor parameter mappings.
Inherited from ClassMap
|
| ReferenceMaps | Member |
The class member reference mappings.
Inherited from ClassMap
|
Methods
| Name | Return Value | Summary |
|---|---|---|
| ApplyAttributes |
void |
Applies attribute configurations to the map.
Inherited from ClassMap
|
| ApplyAttributes |
void |
Applies attribute configurations to the map.
Inherited from ClassMap
|
| ApplyAttributes |
void |
Applies attribute configurations to the map.
Inherited from ClassMap
|
| ApplyAttributes |
void |
Applies attribute configurations to the map.
Inherited from ClassMap
|
| AutoMap |
void |
Auto maps all members for the given type. If a member
is mapped again it will override the existing map.
Inherited from ClassMap
|
| AutoMap |
void |
Auto maps all members for the given type. If a member
is mapped again it will override the existing map.
Inherited from ClassMap
|
| AutoMap |
void |
Auto maps all members for the given type. If a member
is mapped again it will override the existing map.
Inherited from ClassMap
|
| Auto |
void |
Auto maps the given map using constructor parameters.
Inherited from ClassMap
|
| AutoMapMembers |
void |
Auto maps the given map and checks for circular references as it goes.
Inherited from ClassMap
|
| Check |
bool |
Checks for circular references.
Inherited from ClassMap
|
| GetGenericType |
Type |
Gets the generic type for this class map.
Inherited from ClassMap
|
| GetMaxIndex |
int |
Get the largest index for the
members and references.
Inherited from ClassMap
|
| Map |
MemberMap |
Maps a non-member to a CSV field. This allows for writing
data that isn't mapped to a class member.
Inherited from ClassMap
|
| Map |
MemberMap |
Maps a member to a CSV field.
Inherited from ClassMap
|
| Map |
MemberMap |
Maps a member to a CSV field.
|
| Map |
MemberMap |
Maps a member to a CSV field.
|
| Parameter |
ParameterMap |
Maps a constructor parameter to a CSV field.
Inherited from ClassMap
|
| Parameter |
ParameterMap |
Maps a constructor parameter to a CSV field.
Inherited from ClassMap
|
| Parameter |
ParameterMap |
Maps a constructor parameter to a CSV field.
Inherited from ClassMap
|
| References |
MemberReferenceMap |
Maps a member to another class map.
Inherited from ClassMap
|
| References |
MemberReferenceMap |
Meant for internal use only.
Maps a member to another class map. When this is used, accessing a property through
sub-property mapping later won't work. You can only use one or the other. When using
this, ConvertUsing will also not work.
|
| ReIndex |
int |
Resets the indexes based on the given start index.
Inherited from ClassMap
|