reflection, inho, has always been the sign of a bad idea. Reflection .. is
slow and cumbersome and (generally, yes I'm aware of the exceptions) should
NEVER make it to production code.
I would offer up the IS operator (though slightly expensive, it's not bad
compared to reflection) and then do you
On Aug 14, 2012, at 12:00 PM, Goncalo Oliveira wrote:
> Because the content is dynamic and so is the property getter.
I don't fully understand how this works. Is everything truly unbounded, or are
there some type restrictions you can employ?
Do you have an example you can share?
- Jon
__
IE seems to be doing some weird sending/crashing/reposting.
On Thu, Aug 16, 2012 at 7:14 PM, Matthew Leibowitz wrote:
> Hi
>
> Maybe this could give you some ideas: (T4 Templates)
>
>
> <#@ template debug="false" hostspecific="false" language="C#" #>
> <#@ assembly name="System.Core" #>
> <#@ im
Hi
Maybe this could give you some ideas: (T4 Templates)
<#@ template debug="false" hostspecific="false" language="C#" #>
<#@ assembly name="System.Core" #>
<#@ import namespace="System.Reflection" #>
<#@ import namespace="System.Collections.Generic" #>
<#@ output extension=".cs" #>
using System.
fo info in typeof(PropertyInfo).GetProperties())
{
#>
var value<#= info.Name #> = list.<#= info.Name #>;
<#
}
#>
}
}
Sent from my Windows 8 PC <http://windows.microsoft.com/consumer-preview>
*From:* Goncalo Oliveira
*Sent:* 16 August 2012 10:48:09 AM
*To:* Discussions related to Mo
Types and... properties... oh boy, that's gonna be fun!
Well that or... turn off linking on Mono.Android and get a 18mb file.
There should be a way of doing this without all this hassle. At least for a
type's properties. If at least there was a way to teach the linker which
types to preserve and h
Your only option seems to be to completely specialize this routine into
a switch statement that handles all possible types :-/
-- MR
On 14.08.2012 11:26, Goncalo Oliveira wrote:
> I'm kind of lost here. I've found exactly what's failing and where. I
> have some code that's basically trying to do t
No other thoughts?
On 14 August 2012 17:00, Goncalo Oliveira wrote:
> Because the content is dynamic and so is the property getter.
>
>
> On 14 August 2012 16:18, Jonathan Pryor wrote:
>
>> On Aug 14, 2012, at 6:15 AM, Goncalo Oliveira wrote:
>> > The thing is... this is kind of unusable. The
Because the content is dynamic and so is the property getter.
On 14 August 2012 16:18, Jonathan Pryor wrote:
> On Aug 14, 2012, at 6:15 AM, Goncalo Oliveira wrote:
> > The thing is... this is kind of unusable. The whole reason I'm using
> reflection is because I don't know which properties I mi
On Aug 14, 2012, at 6:15 AM, Goncalo Oliveira wrote:
> The thing is... this is kind of unusable. The whole reason I'm using
> reflection is because I don't know which properties I might need.
I don't understand this; why is Reflection preferable to using type checking?
Why wouldn't you know whi
I managed to get around this using the falseflag. Something like this
#pragma warning disable 0219, 0649
static bool falseflag = false;
static SplashActivity()
{
if ( falseflag )
{
var preserveSpinner = new Android.Widget.Spinner(
And
I'm kind of lost here. I've found exactly what's failing and where. I have
some code that's basically trying to do this:
Type targetType = Target.GetType(); // type is Android.Widget.Spinner
PropertyInfo getterProperty = targetType.GetProperty( getterPath );
In release getterProperty is returning
On Jul 24, 2012, at 5:45 AM, Goncalo Oliveira wrote:
> Let me see if I get this straight. I do have an additional project that is
> referenced by the application. It's basically the data model classes. I need
> to add the "[Android.Runtime.Preserve(AllMembers=true)]" attribute to the
> classes
Any more thoughts on this?
Cheers
On 24 July 2012 10:45, Goncalo Oliveira wrote:
> Thank you for the reply Jon.
> It seems that the linker is indeed causing this. I rebuilt with no linking
> and everything works fine. Problem is it generates a 22 mb file instead of
> a 8 mb one.
>
> Let me see
Thank you for the reply Jon.
It seems that the linker is indeed causing this. I rebuilt with no linking
and everything works fine. Problem is it generates a 22 mb file instead of
a 8 mb one.
Let me see if I get this straight. I do have an additional project that is
referenced by the application. I
On Jul 23, 2012, at 12:46 PM, Goncalo Oliveira wrote:
> So... maybe there's a guide somewhere on this? Common errors, things to
> avoid, anything?...
The most common source of errors is due to linking; a type/member that you're
referencing no longer exists:
http://docs.xamarin.com/andro
Hi,
I'm getting a lot of exceptions with the release version that I didn't have
with the debug one.
It's getting hard to trace them all, because even though I can get the
stacktraces from ddms, I can't replicate them in the debug version, so it's
kind of difficult to know what's wrong!
So... mayb
17 matches
Mail list logo