ajperrins / fast-member Goto Github PK
View Code? Open in Web Editor NEWAutomatically exported from code.google.com/p/fast-member
Automatically exported from code.google.com/p/fast-member
IsDefined should exposed the inherit boolean parameter
Original issue reported on code.google.com by [email protected]
on 27 Jan 2015 at 6:45
Attachments:
Here is your code
As you can see allowNonPublicAccessors is not used
/// <summary>
/// Wraps an individual object, allowing by-name access to that instance
///
/// </summary>
public static ObjectAccessor Create(object target, bool allowNonPublicAccessors)
{
if (target == null)
throw new ArgumentNullException("target");
IDynamicMetaObjectProvider target1 = target as IDynamicMetaObjectProvider;
if (target1 != null)
return (ObjectAccessor) new ObjectAccessor.DynamicWrapper(target1);
else
return (ObjectAccessor) new ObjectAccessor.TypeAccessorWrapper(target, TypeAccessor.Create(target.GetType()));
}
Original issue reported on code.google.com by [email protected]
on 28 Nov 2014 at 3:20
What steps will reproduce the problem?
1. Set starting project of solution to FastMember_Net35
2. Do a build / compile
3. It will complain about System.Dynamic not found
2 possible workaround / solution for this:
Either:
Change Conditional Compilation symbols from NET20 to NO_DYNAMIC
-or-
Change compiler directives in codes from:
#if !NO_DYNAMIC
...
#endif
to:
#if !NET20
...
#endif
Original issue reported on code.google.com by [email protected]
on 30 Apr 2012 at 12:36
To Github or Bitbucket, before Google Code shuts down
Original issue reported on code.google.com by [email protected]
on 28 May 2015 at 5:49
What steps will reproduce the problem?
1. hg clone https://code.google.com/p/fast-member/
2. cd fast-member
3. C:\Windows\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe .\FastMember.sln
What is the expected output? What do you see instead?
Build Successful ( this _did_ work initially when the project was released last
night. this is on a different machine )
What version of the product are you using? On what operating system?
head 1.0.0.2 i believe
Please provide any additional information below.
VS2010 on a Win7 x64 machine.
Original issue reported on code.google.com by [email protected]
on 13 Jan 2012 at 11:44
How can we make ti working with static properties?
Here is a sample to product problem:
var accessor = TypeAccessor.Create(typeof (DateTime));
var now = accessor[null, "Now"];
Regards,
Original issue reported on code.google.com by [email protected]
on 20 Nov 2014 at 10:50
What steps will reproduce the problem?
1.
This enum:
----------
public enum EnumA
{
One,
Two,
Three
}
This class:
-----------
public class ClassD
{
private EnumA _foo;
public void SetFoo(EnumA foo)
{
_foo = foo;
}
public EnumA GetFoo()
{
return _foo;
}
}
This test:
----------
[Test]
public void Cant_deserialize_enum()
{
var value = new ClassD();
value.SetFoo(EnumA.One);
var accessor = TypeAccessor.Create(typeof(ClassD));
var accessed = accessor[value, "_foo"];
var foo = (EnumA)accessed;
}
What is the expected output? What do you see instead?
It should deserialize--flipping _foo to a public field shows correct behavior,
private results in ArgumentOutOfRangeException
What version of the product are you using? On what operating system?
Please provide any additional information below.
Original issue reported on code.google.com by daniel.crenna
on 6 Apr 2014 at 4:40
I have a clone in which I've added caching of property and field names. Not
sure if this is of any interest, but it's here if you want:
http://code.google.com/r/kearonsean-fast-member/source/detail?r=6488edf35577a727
1a39472e72654650b36e627e
Original issue reported on code.google.com by [email protected]
on 13 May 2012 at 10:48
The method TypeAccessor.WriteSetter throws an ArgumentNullException, if the
target type has a property with a non-public setter. (Line 141:
http://code.google.com/p/fast-member/source/browse/FastMember/TypeAccessor.cs#14
1)
Example:
class TestTarget
{
public int Id { get; private set; }
}
I am not sure why `prop.GetSetMethod()` returns `null`, although
`prop.CanWrite` obviously returned `true` in line 129.
Original issue reported on code.google.com by [email protected]
on 27 Jan 2012 at 8:22
It would be nice to be able to pull out the PropertyInfo / FieldInfo array
results created when the accessor is created. In my use case, I need to build
TypeAccessors off of anonymous types that "look" like the real typed
counterpart. In these cases I only want to know what properties in the
anonymous type match the static type (to avoid crashing on a bad get). I've
patched my version to provide these results so I don't have to take another
reflection hit outside of the library to do the same thing, but it might be
worth adding for everyone. Not worth a patch, it's just trivially exposing
"props" and "fields" as instance properties.
Original issue reported on code.google.com by daniel.crenna
on 24 Oct 2012 at 8:06
Fix is to perform the same check for private types when building a MemberSet
Original issue reported on code.google.com by daniel.crenna
on 14 Jan 2015 at 2:31
The FastMember.dll assembly is not strongly signed.
Original issue reported on code.google.com by pvginkel
on 29 Jan 2012 at 7:12
If you change the code from
il.Emit(OpCodes.Ldstr, "name");
il.Emit(OpCodes.Newobj, typeof(ArgumentOutOfRangeException).GetConstructor(new
Type[] { typeof(string) }));
il.Emit(OpCodes.Throw);
To this:
il.Emit(OpCodes.Ldarg, 2);
il.Emit(OpCodes.Newobj, typeof(ArgumentOutOfRangeException).GetConstructor(new
Type[] { typeof(string) }));
il.Emit(OpCodes.Throw);
It'll shown you the actual Argument name that is causing the issue, at the
moment it just says the parameter name is "name"
This could be changed here
http://code.google.com/p/fast-member/source/browse/FastMember/TypeAccessor.cs#11
3 and
http://code.google.com/p/fast-member/source/browse/FastMember/TypeAccessor.cs#16
8 and
Original issue reported on code.google.com by [email protected]
on 2 May 2012 at 5:00
public class Foo
{
public string _str;
public Foo(string str)
{
_str = str;
}
}
Original issue reported on code.google.com by [email protected]
on 22 Nov 2012 at 2:15
While trying the set or get a property from a COM object using the
ObjectAccessor, it always throw an ArgumentOutOfRangeException.
Original issue reported on code.google.com by [email protected]
on 3 Apr 2012 at 9:27
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.