The official Fatica Labs Blog! RSS 2.0
# Wednesday, 02 November 2011

Sometimes when we use mapping by code we want to see the generated HBM, just to understand if all is working as expected. I did this in some my old posts by dumping the hbm with an helper method, but I simply miss that the function exists as an extension method. Here below an example:

 var compiled = mapper.CompileMappingForAllExplicitlyAddedEntities();


We simply need to include the following using:

using NHibernate.Mapping.ByCode;

Here I use the AsString method that serialize in a string the compiled mapping.
Wednesday, 02 November 2011 14:39:29 (GMT Standard Time, UTC+00:00)  #    Comments [0] - Trackback
NH Mapping By Code | NHibernate

# Tuesday, 01 November 2011

In order to start with Azure we need to prepare our Visual Studio with the azure SDK. Even if the Windows Azure tools for Microsoft Visual Studio is only supported by Visual Studio 2010 & Visual Studio 2010 SP1 editions, you can download a standalone SDK providing low level tools, the API ( ie the client dll ) the documentation and the samples we need for start.

So the first step is downloading the Windows Azure SDK and install it. After the installation is complete you will see this in your Server Explorer:


So the new computer and barrels painted in azure means that we have the emulators for the compute service and storage locally running, this mean we can start to try something without buy a real account in the cloud with jus few differences. First time you expand the Storage a backend for it is created under SQL Express, but you can use another SQL server instance by following these instructions.

Another gift from Visual Studio Tools are the new application templates:


This is enough to get the environment ready on.

Tuesday, 01 November 2011 08:34:48 (GMT Standard Time, UTC+00:00)  #    Comments [0] - Trackback
azure | cloud

# Tuesday, 25 October 2011

I’m starting to learn something about cloud computing, probably with Azure: just because I’m a little .NET biased Smile 


What I like in the Cloud approach is the hardware availability – scalability. As a drawback we need even more broad band reliable collection, thinking on something like this, because the whole strategy fails if the end connection, the one with the user, fails or it is poor.

Now what we need is just a rocking idea to start…

Tuesday, 25 October 2011 14:24:18 (GMT Daylight Time, UTC+01:00)  #    Comments [0] - Trackback
communication | technology

# Thursday, 20 October 2011

Since it is boring having to specify every time the Schema a table belongs to, it would be nice having a conventional strategy to automatically wire up this information. With NHibernate mapping by code functionality this is simple. The strategy I propose is having the last part of the entity namespace being equal with the schema. So for example we have an entity Product in the schema named Production we define the entity as:


Then by using a ConventionModelMapper we can write:

public class MyModelMapper:ConventionModelMapper
        public MyModelMapper()
            this.BeforeMapClass += (modelInspector, type, customizer) =>

And we achieve to write less line again :)

Thursday, 20 October 2011 12:05:18 (GMT Daylight Time, UTC+01:00)  #    Comments [1] - Trackback
NH Mapping By Code | NHibernate

# Tuesday, 11 October 2011

As I said in this post I' have been working on an helper library to encapsulate the extra work we should do in presenting big dataset to the user: limiting the resultset. I wrote a 5 minutes demo to show how the interface could appear reactive, based on NHibernate - Caliburn-and FlyFetch. This does not mean that Flyfetch depends on some way on these library, is just to have something to show very quickly. The present FlyFetch version is not bound to any presentation technology to ( even if RIA and WPF applications are probably the best candidates to use ).   The application requires to have AdventureWorks to so since the prerequisite are not trivial I decided to grab a little video of the sample app running, just to show the reactivity we can achieve with FlyFetch.

FlyFetch in a demo app

I managed to remove any proxy engine dependency ( I use an internal proxy factory to create a special custom proxy ), and I managed to have an MVVM friendly component since the pager works independently from the view.You are welcome to follow FlyFetch at this address, or simply fork your version here. As an update, I used flyfetch with success in production too :)

Tuesday, 11 October 2011 20:54:13 (GMT Daylight Time, UTC+01:00)  #    Comments [0] - Trackback
CodeProject | FlyFetch | MVVM | WPF

# Friday, 07 October 2011

The current implementation using SynchroVisible and With fails when there is more than three chart to synchronize. So I modified the code and added a central agent to keep in synch more charts. We just need to define an instance of it as a resource:


        <ddd:MultiChartSynchronizer x:Key="mainSynchro"/>

and then “subscribe” each chart to keep in synch with:

<ddd:ChartPlotter x:Name="price" ddd:SynchroVisible.Axis="X" 
ddd:SynchroVisible.Using="{StaticResource mainSynchro}"
LegendVisibility="Hidden" NewLegendVisible="False" Grid.Row="1">

obviously we can have multiple instance of synchronizer object to create more context in which chart align.

You can find and follow this project on Bitbucket.

Friday, 07 October 2011 17:24:31 (GMT Daylight Time, UTC+01:00)  #    Comments [1] - Trackback
D3 | WPF

My Stack Overflow

Send mail to the author(s) E-mail

profile for Felice Pollano at Stack Overflow, Q&A for professional and enthusiast programmers
About the author/Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.

© Copyright 2019
Felice Pollano
Sign In
Total Posts: 157
This Year: 0
This Month: 0
This Week: 0
Comments: 127
This blog visits
All Content © 2019, Felice Pollano
DasBlog theme 'Business' created by Christoph De Baene (delarou) and modified by Felice Pollano
Nike Winkels Nederland Outlet Nike Nederland Store Outlet Nike Nederland 2015 Outlet Nike Outlet Online Nike Sneakers Outlet