Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
Dapper
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
tsai
Dapper
Commits
df9fe51e
Commit
df9fe51e
authored
May 18, 2011
by
Sam
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #5 from nberardi/master
Adding IDictionary<string,object> to FastExpando
parents
b5fa7cf0
914da800
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
104 additions
and
1 deletion
+104
-1
SqlMapper.cs
Dapper/SqlMapper.cs
+104
-1
No files found.
Dapper/SqlMapper.cs
View file @
df9fe51e
...
@@ -474,7 +474,7 @@ private static CacheInfo GetCacheInfo(object param, Identity identity)
...
@@ -474,7 +474,7 @@ private static CacheInfo GetCacheInfo(object param, Identity identity)
}
}
#if !CSHARP30
#if !CSHARP30
private
class
FastExpando
:
System
.
Dynamic
.
DynamicObject
private
class
FastExpando
:
System
.
Dynamic
.
DynamicObject
,
IDictionary
<
string
,
object
>
{
{
IDictionary
<
string
,
object
>
data
;
IDictionary
<
string
,
object
>
data
;
...
@@ -493,6 +493,109 @@ public override bool TryGetMember(System.Dynamic.GetMemberBinder binder, out obj
...
@@ -493,6 +493,109 @@ public override bool TryGetMember(System.Dynamic.GetMemberBinder binder, out obj
{
{
return
data
.
TryGetValue
(
binder
.
Name
,
out
result
);
return
data
.
TryGetValue
(
binder
.
Name
,
out
result
);
}
}
#
region
IDictionary
<
string
,
object
>
Members
void
IDictionary
<
string
,
object
>.
Add
(
string
key
,
object
value
)
{
throw
new
NotImplementedException
();
}
bool
IDictionary
<
string
,
object
>.
ContainsKey
(
string
key
)
{
return
data
.
ContainsKey
(
key
);
}
ICollection
<
string
>
IDictionary
<
string
,
object
>.
Keys
{
get
{
return
data
.
Keys
;
}
}
bool
IDictionary
<
string
,
object
>.
Remove
(
string
key
)
{
throw
new
NotImplementedException
();
}
bool
IDictionary
<
string
,
object
>.
TryGetValue
(
string
key
,
out
object
value
)
{
return
data
.
TryGetValue
(
key
,
out
value
);
}
ICollection
<
object
>
IDictionary
<
string
,
object
>.
Values
{
get
{
return
data
.
Values
;
}
}
object
IDictionary
<
string
,
object
>.
this
[
string
key
]
{
get
{
return
data
[
key
];
}
set
{
throw
new
NotImplementedException
();
}
}
#
endregion
#
region
ICollection
<
KeyValuePair
<
string
,
object
>>
Members
void
ICollection
<
KeyValuePair
<
string
,
object
>>.
Add
(
KeyValuePair
<
string
,
object
>
item
)
{
throw
new
NotImplementedException
();
}
void
ICollection
<
KeyValuePair
<
string
,
object
>>.
Clear
()
{
throw
new
NotImplementedException
();
}
bool
ICollection
<
KeyValuePair
<
string
,
object
>>.
Contains
(
KeyValuePair
<
string
,
object
>
item
)
{
return
data
.
Contains
(
item
);
}
void
ICollection
<
KeyValuePair
<
string
,
object
>>.
CopyTo
(
KeyValuePair
<
string
,
object
>[]
array
,
int
arrayIndex
)
{
data
.
CopyTo
(
array
,
arrayIndex
);
}
int
ICollection
<
KeyValuePair
<
string
,
object
>>.
Count
{
get
{
return
data
.
Count
;
}
}
bool
ICollection
<
KeyValuePair
<
string
,
object
>>.
IsReadOnly
{
get
{
return
true
;
}
}
bool
ICollection
<
KeyValuePair
<
string
,
object
>>.
Remove
(
KeyValuePair
<
string
,
object
>
item
)
{
throw
new
NotImplementedException
();
}
#
endregion
#
region
IEnumerable
<
KeyValuePair
<
string
,
object
>>
Members
IEnumerator
<
KeyValuePair
<
string
,
object
>>
IEnumerable
<
KeyValuePair
<
string
,
object
>>.
GetEnumerator
()
{
return
data
.
GetEnumerator
();
}
#
endregion
#
region
IEnumerable
Members
IEnumerator
IEnumerable
.
GetEnumerator
()
{
return
data
.
GetEnumerator
();
}
#
endregion
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment