File tree Expand file tree Collapse file tree 2 files changed +26
-0
lines changed Expand file tree Collapse file tree 2 files changed +26
-0
lines changed Original file line number Diff line number Diff line change 1
1
using System ;
2
+ #if ! NETSTANDARD1_3
3
+ using System . Runtime . Serialization ;
4
+ #endif
2
5
3
6
namespace MySqlConnector
4
7
{
5
8
/// <summary>
6
9
/// <see cref="MySqlConversionException"/> is thrown when a MySQL value can't be converted to another type.
7
10
/// </summary>
11
+ #if ! NETSTANDARD1_3
12
+ [ Serializable ]
13
+ #endif
8
14
public class MySqlConversionException : Exception
9
15
{
10
16
/// <summary>
@@ -15,5 +21,12 @@ public MySqlConversionException(string message)
15
21
: base ( message )
16
22
{
17
23
}
24
+
25
+ #if ! NETSTANDARD1_3
26
+ private MySqlConversionException ( SerializationInfo info , StreamingContext context )
27
+ : base ( info , context )
28
+ {
29
+ }
30
+ #endif
18
31
}
19
32
}
Original file line number Diff line number Diff line change 1
1
using System ;
2
+ #if ! NETSTANDARD1_3
3
+ using System . Runtime . Serialization ;
4
+ #endif
2
5
using MySqlConnector . Utilities ;
3
6
4
7
namespace MySqlConnector
5
8
{
6
9
/// <summary>
7
10
/// <see cref="MySqlProtocolException"/> is thrown when there is an internal protocol error communicating with MySQL Server.
8
11
/// </summary>
12
+ #if ! NETSTANDARD1_3
13
+ [ Serializable ]
14
+ #endif
9
15
public sealed class MySqlProtocolException : InvalidOperationException
10
16
{
11
17
/// <summary>
@@ -17,6 +23,13 @@ public sealed class MySqlProtocolException : InvalidOperationException
17
23
internal static MySqlProtocolException CreateForPacketOutOfOrder ( int expectedSequenceNumber , int packetSequenceNumber ) =>
18
24
new MySqlProtocolException ( "Packet received out-of-order. Expected {0}; got {1}." . FormatInvariant ( expectedSequenceNumber , packetSequenceNumber ) ) ;
19
25
26
+ #if ! NETSTANDARD1_3
27
+ private MySqlProtocolException ( SerializationInfo info , StreamingContext context )
28
+ : base ( info , context )
29
+ {
30
+ }
31
+ #endif
32
+
20
33
private MySqlProtocolException ( string message )
21
34
: base ( message )
22
35
{
You can’t perform that action at this time.
0 commit comments