-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Reduce the need for custom expressions. (#144)
Reducing the need for custom expressions in literal member maps.
- Loading branch information
Showing
10 changed files
with
593 additions
and
327 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 15 additions & 7 deletions
22
...ns.ExpressionMapping/Resource.Designer.cs → ...nMapping/Properties/Resources.Designer.cs
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
146 changes: 146 additions & 0 deletions
146
src/AutoMapper.Extensions.ExpressionMapping/Properties/Resources.resx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,146 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<root> | ||
<!-- | ||
Microsoft ResX Schema | ||
Version 1.3 | ||
The primary goals of this format is to allow a simple XML format | ||
that is mostly human readable. The generation and parsing of the | ||
various data types are done through the TypeConverter classes | ||
associated with the data types. | ||
Example: | ||
... ado.net/XML headers & schema ... | ||
<resheader name="resmimetype">text/microsoft-resx</resheader> | ||
<resheader name="version">1.3</resheader> | ||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader> | ||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader> | ||
<data name="Name1">this is my long string</data> | ||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data> | ||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64"> | ||
[base64 mime encoded serialized .NET Framework object] | ||
</data> | ||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> | ||
[base64 mime encoded string representing a byte array form of the .NET Framework object] | ||
</data> | ||
There are any number of "resheader" rows that contain simple | ||
name/value pairs. | ||
Each data row contains a name, and value. The row also contains a | ||
type or mimetype. Type corresponds to a .NET class that support | ||
text/value conversion through the TypeConverter architecture. | ||
Classes that don't support this are serialized and stored with the | ||
mimetype set. | ||
The mimetype is used for serialized objects, and tells the | ||
ResXResourceReader how to depersist the object. This is currently not | ||
extensible. For a given mimetype the value must be set accordingly: | ||
Note - application/x-microsoft.net.object.binary.base64 is the format | ||
that the ResXResourceWriter will generate, however the reader can | ||
read any of the formats listed below. | ||
mimetype: application/x-microsoft.net.object.binary.base64 | ||
value : The object must be serialized with | ||
: System.Serialization.Formatters.Binary.BinaryFormatter | ||
: and then encoded with base64 encoding. | ||
mimetype: application/x-microsoft.net.object.soap.base64 | ||
value : The object must be serialized with | ||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter | ||
: and then encoded with base64 encoding. | ||
mimetype: application/x-microsoft.net.object.bytearray.base64 | ||
value : The object must be serialized into a byte array | ||
: using a System.ComponentModel.TypeConverter | ||
: and then encoded with base64 encoding. | ||
--> | ||
|
||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata"> | ||
<xsd:element name="root" msdata:IsDataSet="true"> | ||
<xsd:complexType> | ||
<xsd:choice maxOccurs="unbounded"> | ||
<xsd:element name="data"> | ||
<xsd:complexType> | ||
<xsd:sequence> | ||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" /> | ||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" /> | ||
</xsd:sequence> | ||
<xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" /> | ||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" /> | ||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" /> | ||
</xsd:complexType> | ||
</xsd:element> | ||
<xsd:element name="resheader"> | ||
<xsd:complexType> | ||
<xsd:sequence> | ||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" /> | ||
</xsd:sequence> | ||
<xsd:attribute name="name" type="xsd:string" use="required" /> | ||
</xsd:complexType> | ||
</xsd:element> | ||
</xsd:choice> | ||
</xsd:complexType> | ||
</xsd:element> | ||
</xsd:schema> | ||
<resheader name="resmimetype"> | ||
<value>text/microsoft-resx</value> | ||
</resheader> | ||
<resheader name="version"> | ||
<value>1.3</value> | ||
</resheader> | ||
<resheader name="reader"> | ||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.3500.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> | ||
</resheader> | ||
<resheader name="writer"> | ||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.3500.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> | ||
</resheader> | ||
<data name="cannotCreateBinaryExpressionFormat" xml:space="preserve"> | ||
<value>Cannot create a binary expression for the following pair. Node: {0}, Type: {1} and Node: {2}, Type: {3}.</value> | ||
<comment>0=leftNode; 1=leftNodeType; 2=rightNode; 3=rightNodeType</comment> | ||
</data> | ||
<data name="cantRemapExpression" xml:space="preserve"> | ||
<value>Can't rempa expression</value> | ||
</data> | ||
<data name="expressionMapValueTypeMustMatchFormat" xml:space="preserve"> | ||
<value>The source and destination types must be the same for expression mapping between literal types. Source Type: {0}, Source Description: {1}, Destination Type: {2}, Destination Property: {3}.</value> | ||
<comment>0=Source Type; 1=SourceDescription; 2=Destination Type; 3=Destination Property.</comment> | ||
</data> | ||
<data name="includeExpressionTooComplex" xml:space="preserve"> | ||
<value>The Include value-type expression uses multiple sibling navigation objects "{0}", "{1}" and is too complex to translate.</value> | ||
<comment>0=FirstNavigationProperty, 1=SecondNavigationProperty</comment> | ||
</data> | ||
<data name="invalidArgumentCount" xml:space="preserve"> | ||
<value>Source and destination must have the same number of arguments.</value> | ||
</data> | ||
<data name="invalidExpErr" xml:space="preserve"> | ||
<value>Invalid expression type for this operation.</value> | ||
</data> | ||
<data name="mapperInfoDictionaryIsNull" xml:space="preserve"> | ||
<value>Mapper Info dictionary cannot be null.</value> | ||
</data> | ||
<data name="srcMemberCannotBeNullFormat" xml:space="preserve"> | ||
<value>SourceMember cannot be null. Source Type: {0}, Destination Type: {1}, Property: {2}.</value> | ||
<comment>0=SorceType; 1=DestinationType; 2=Name of the source property</comment> | ||
</data> | ||
<data name="typeMappingsDictionaryIsNull" xml:space="preserve"> | ||
<value>Type Mappings dictionary cannot be null.</value> | ||
</data> | ||
<data name="customResolversNotSupported" xml:space="preserve"> | ||
<value>Custom resolvers are not supported for expression mapping.</value> | ||
</data> | ||
<data name="mustBeExpressions" xml:space="preserve"> | ||
<value>Arguments must be expressions.</value> | ||
</data> | ||
<data name="mappedMemberIsChildOfTheParameterFormat" xml:space="preserve"> | ||
<value>The mapped member {0} is of type {1} and a child of the parameter type {2}. No reference type (parent of) {0} is available to map as an include.</value> | ||
<comment>0=memberName, 1=memberType; 2=parameterType</comment> | ||
</data> | ||
<data name="makeParentTypesMatchForMembersOfLiteralsFormat" xml:space="preserve"> | ||
<value>For members of literal types, use IMappingExpression.ForMember() to make the parent property types an exact match. Parent Source Type: {0}, Parent Destination Type: {1}, Full Member Name "{2}".</value> | ||
<comment>0=typeSource, 1=typeDestination; 2=sourceFullName</comment> | ||
</data> | ||
</root> |
Oops, something went wrong.