This conversation spurred a blog post: 
http://brendanjerwin.github.com/2009/03/11/using-nhibernate-validator-with-fluent-nhibernate.html

:) Maybe google will show that to the next person trying to integrate  
the two...

On Mar 10, 2009, at 6:09 PM, Brendan Erwin wrote:

> RE: "fluent-nhibernate spit out the mappings it generates and then  
> load them each into the Validator configuration."
>
> I was trying to get it configured using the  
> ValidatorEngine.Configure method instead of the  
> ValidatorInitializer. fluentnh can write the mapping xml out to disk  
> so I was going to load each of those .xml files individually.
>
> The ValidatorInitializer seems like a better approach.
>
> I'll read your post also.
>
> On Mar 10, 2009, at 2:56 PM, Fabio Maulo wrote:
>
>> What do you mean with
>> "fluent-nhibernate spit out the mappings it generates and then load  
>> them each into the Validator configuration."
>>
>> Do you want load persistent mappings in NHV ? I don't understand  
>> the point.
>> If you are using ValidatorInitializer the work is done inside  
>> events it mean that the events initialization will initialize the  
>> ValidatorEngine for all persistent classes are registered in the  
>> sessionFactory.
>> Only take care about set the SharedEngineProvider.
>> http://fabiomaulo.blogspot.com/2009/02/diving-in-nhibernatevalidator.html
>>
>>
>> 2009/3/10 Fabio Maulo <[email protected]>
>> The ValidatorEngine.Configure no but you said:
>> "I'm trying to get Validator to work with mappings created with  
>> fluent-nhibernate."
>> and I thought it was ValidatorInitializer because there is not  
>> another integration point between NH and NHV
>>
>> 2009/3/10 Brendan Erwin <[email protected]>
>>
>> I'm missing something here. fluent-nhibernate does give me access  
>> to the NHibernate Configuration before BuildSessionFactory but I  
>> don't see what to do with it. The ValidatorEngine.Configure method  
>> does not take an instance of NHibernate.Cfg.Configuration.
>>
>>
>> On Mar 10, 2009, at 2:11 PM, Fabio Maulo wrote:
>>
>>> FNH should give you something before BuildSessionFactory.
>>> something = the configuration with all mappings added.
>>>
>>> Then you have a full integration.
>>>
>>> P.S. take a look to Loquacious 
>>> (http://fabiomaulo.blogspot.com/2009/02/nhibernatevalidator-fluent-interface.html
>>>  
>>>  )
>>> Available on NHV trunk.
>>>
>>> 2009/3/10 brendanjerwin <[email protected]>
>>>
>>> I'm trying to get Validator to work with mappings created with  
>>> fluent-
>>> nhibernate. Currently the best plan I have is to have fluent-
>>> nhibernate spit out the mappings it generates and then load them  
>>> each
>>> into the Validator configuration.
>>>
>>> Is there any better approach?
>>>
>>>
>>>
>>>
>>> -- 
>>> Fabio Maulo
>>>
>>>
>>>
>>
>>
>>
>>
>>
>>
>>
>> -- 
>> Fabio Maulo
>>
>>
>>
>> -- 
>> Fabio Maulo
>>
>> >>
>


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"nhusers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/nhusers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to