archive-be.com » BE » B » BENNYMICHIELSEN.BE

Total: 348

Choose link from "Titles, links and description words view":

Or switch to "Titles and links view".
  • Add aspects at runtime without xml to your spring context – Benny Michielsen
    string objectName object PostProcessBeforeInitialization object instance string name The documentation states that the processors that populate entities via marker attributes should use the PostProcessBeforeInitialization where as postprocessors that wrap objects with proxies should use PostProcessAfterInitialization In this case it s clear that since we will create a proxy we need to implement the latter public object PostProcessAfterInitialization object instance string objectName if InstanceShouldBeProxied instance ProxyFactory factory new ProxyFactory instance factory AddAdvice new WriteLineAspect return factory GetProxy return instance The implementation is rather straightforward The postprocessor has a collection of all the types it should intercept and checks each instance it is handed If there is a match it will create a proxyfactory add the advice and create a proxy Otherwise it just returns the instance The application context in Spring automatically picks up any processors it has and will hook it up for you When deployed in an objectfactory however you need to explicitly register it The only thing left to add now is the configuration part for the postprocessor which is demonstrated in the sample below private static void RegisterPostProcessor GenericApplicationContext context MyPostProcessor postProcessor new MyPostProcessor postProcessor InterceptInstancesOfInterface typeof ITaksService context ObjectFactory AddObjectPostProcessor postProcessor Full source code is available here Program cs 3 50 kb Author BennyM Posted on 21 01 2009 Categories Spring NET Tags aop Leave a Reply Cancel reply Your email address will not be published Required fields are marked Comment Name Email Website Post navigation Previous Previous post Yet another Windows 7 post Next Next post Windows 7 day 2 Search Search for Search Follow me Recent Comments Rick on Partitioning and wildcards in an Azure Data Factory pipeline BennyM on WCF HTTPS And Request Entity Too Large Justin on WCF HTTPS And Request Entity Too Large The Morning Brew Chris Alcock The Morning Brew

    Original URL path: http://blog.bennymichielsen.be/2009/01/21/add-aspects-at-runtime-without-xml-to-your-spring-context/ (2016-04-29)
    Open archived version from archive



  • context ObjectFactory AddObjectPostProcessor postProcessor static void RegisterTaskService GenericApplicationContext context IObjectDefinitionFactory objectDefinitionFactory new DefaultObjectDefinitionFactory ObjectDefinitionBuilder builder ObjectDefinitionBuilder RootObjectDefinition objectDefinitionFactory typeof TaskService context RegisterObjectDefinition TaskService builder ObjectDefinition public interface ITaksService void DoIt public class TaskService ITaksService region ITaksService Members public void DoIt Console WriteLine Doing my stuff endregion public class WriteLineAspect AopAlliance Intercept IMethodInterceptor region IMethodInterceptor Members public object Invoke AopAlliance Intercept IMethodInvocation invocation Console WriteLine Calling object returnValue invocation Proceed Console

    Original URL path: http://blog.bennymichielsen.be/wp-content/uploads/2009/1/Program.cs.txt (2016-04-29)
    Open archived version from archive

  • Yet another Windows 7 post – Benny Michielsen
    by Billy Hollis Next Next post Add aspects at runtime without xml to your spring context Search Search for Search Follow me Recent Comments Rick on Partitioning and wildcards in an Azure Data Factory pipeline BennyM on WCF HTTPS And Request Entity Too Large Justin on WCF HTTPS And Request Entity Too Large The Morning Brew Chris Alcock The Morning Brew 2052 on Getting up and running with Mono and

    Original URL path: http://blog.bennymichielsen.be/2009/01/20/yet-another-windows-7-post/ (2016-04-29)
    Open archived version from archive

  • virtualbox – Benny Michielsen
    so I need Visual Studio and Windows to get my work done and apart from the fact that some keys don t work or I haven t figured out how to get them working like the function keys I don t feel any difference compared to working on a native Windows box You don t loose any responsiveness Copy Pasting text is supported so I can copy text from i e Safari into Notepad While skimming through the manual there was a mention on how to share files between the two operating systems but I haven t really looked into that It works with shared folders to achieve this functionality the two other virtualisation options support drag and drop I think You can run VirtualBox as any other window but most of the time I run it in seamless mode This means that the applications you start in Windows can be placed next to your running OS X applications seamlessly This is illustrated by the attached screenshots the first one shows the Windows applications locked on the Windows desktop and the second one shows the same applications but now running in seamless mode I first used spaces to keep my OS X and Windows applications separated but found that not comfortably to work in I would look something up in Safari then switch to Visual Studio and saw all the applications fly from left to right a few minutes later I d receive a mail and everything flew back again If there would be one school example on why to use spaces I thought it would be virtualisation but now I m not convinced of the entire idea any more Why on earth would you use it except for adding more icons on your desktop So to sum it up

    Original URL path: http://blog.bennymichielsen.be/tag/virtualbox/ (2016-04-29)
    Open archived version from archive

  • WPF Application by Billy Hollis – Benny Michielsen
    navigation Previous Previous post Mapping a list of components with Fluent NHibernate Next Next post Yet another Windows 7 post Search Search for Search Follow me Recent Comments Rick on Partitioning and wildcards in an Azure Data Factory pipeline BennyM on WCF HTTPS And Request Entity Too Large Justin on WCF HTTPS And Request Entity Too Large The Morning Brew Chris Alcock The Morning Brew 2052 on Getting up and

    Original URL path: http://blog.bennymichielsen.be/2009/01/20/wpf-application-by-billy-hollis/ (2016-04-29)
    Open archived version from archive

  • example – Benny Michielsen
    WPF Application by Billy Hollis Search Search for Search Follow me Recent Comments Rick on Partitioning and wildcards in an Azure Data Factory pipeline BennyM on WCF HTTPS And Request Entity Too Large Justin on WCF HTTPS And Request Entity Too Large The Morning Brew Chris Alcock The Morning Brew 2052 on Getting up and running with Mono and Raspberry Pi 3 bhldev on Exposing iCal data in WebAPI Archives

    Original URL path: http://blog.bennymichielsen.be/tag/example/ (2016-04-29)
    Open archived version from archive

  • Mapping a list of components with Fluent NHibernate – Benny Michielsen
    different name compared to the entity diagram p The mapping for the Language entity is pretty straightforward The mapping for the ActivityType and its localizations was a bigger challenge since I got lost in all the delegates after the Component method public class LanuageMapping ClassMap Language public LanuageMapping Id x x Id Map x x Name WithTable 7de Languages public class ActivityTypeMapping ClassMap ActivityType public ActivityTypeMapping WithTable 7de EventTypes Id activityType activityType Id Map activityType activityType IconName HasMany LocalizedEntity activityType activityType Descriptions WithTableName 7de LocalizedEventTypes Component description description References Language desc desc Language CanNotBeNull description Map desc desc Localization CanNotBeNull Author BennyM Posted on 05 01 2009 Categories Software Development Tags fluent nhibernate nhibernate 3 thoughts on Mapping a list of components with Fluent NHibernate Miguel Marques says 22 01 2010 at 13 14 Hi i was mapping a similar model but the problem is that using an analogy with your example it says that LocalizedEntity is not mapped Reply Benny Michielsen says 23 01 2010 at 15 34 This worked at the time of writing this post Haven t checked it out recently will add it on my todo list Sorry I can t be of any more help at the moment Reply Miguel Marques says 04 02 2010 at 19 16 You are right i had another problem in the mapping its works fine Reply Leave a Reply Cancel reply Your email address will not be published Required fields are marked Comment Name Email Website Post navigation Previous Previous post Apple developing home media server Next Next post WPF Application by Billy Hollis Search Search for Search Follow me Recent Comments Rick on Partitioning and wildcards in an Azure Data Factory pipeline BennyM on WCF HTTPS And Request Entity Too Large Justin on WCF HTTPS And Request Entity

    Original URL path: http://blog.bennymichielsen.be/2009/01/05/mapping-a-list-of-components-with-fluent-nhibernate/ (2016-04-29)
    Open archived version from archive

  • Apple developing home media server – Benny Michielsen
    Post navigation Previous Previous post Virtualisation with VirtualBox Next Next post Mapping a list of components with Fluent NHibernate Search Search for Search Follow me Recent Comments Rick on Partitioning and wildcards in an Azure Data Factory pipeline BennyM on WCF HTTPS And Request Entity Too Large Justin on WCF HTTPS And Request Entity Too Large The Morning Brew Chris Alcock The Morning Brew 2052 on Getting up and running

    Original URL path: http://blog.bennymichielsen.be/2009/01/04/apple-developing-home-media-server/ (2016-04-29)
    Open archived version from archive