Up Property interceptors
DevForce 2010 Resource Center » DevForce development » Model » Property interceptors » EntityProperties and property interceptors

EntityProperties and property interceptors

Last modified on October 27, 2011 13:04
Contents

Within a DevForce entity, every property has a GetterInterceptor and a SetterInterceptor. These interceptors can be used to add or remove the AddAction actions associated with that property. Under the covers this is going through the PropertyInterceptorManager mechanism, but the syntax is often simpler. For example:

C#
Employee.PropertyMetadata.Title.GetterInterceptor.AddAction(
  IbCore.PropertyInterceptorTiming.Before,
    args => args.Value = args.Value.ToUpper());
VB
Employee.PropertyMetadata.Title.GetterInterceptor.AddAction( _
  IbCore.PropertyInterceptorTiming.Before, Function(args) _
    args.Value = args.Value.ToUpper())
Created by DevForce on October 07, 2010 14:20

This wiki is licensed under a Creative Commons 2.0 license. XWiki Enterprise 3.2 - Documentation. Copyright © 2015 IdeaBlade