Exemple #1
0
 public override void Deactivate(IActivationContext context)
 {
     if (context.Depth().RequiresActivation())
     {
         CascadeActivation(context);
     }
     SetOn(context.Transaction(), context.TargetObject(), null);
 }
 protected object CascadingTarget(IActivationContext context)
 {
     if (context.Depth().Mode().IsDeactivate())
     {
         if (null == _reflectField)
         {
             return(null);
         }
         return(FieldAccessor().Get(_reflectField, context.TargetObject()));
     }
     return(GetOrCreate(context.Transaction(), context.TargetObject()));
 }
		public override void Deactivate(IActivationContext context)
		{
			if (context.Depth().RequiresActivation())
			{
				CascadeActivation(context);
			}
			SetOn(context.Transaction(), context.TargetObject(), null);
		}
Exemple #4
0
		private bool ProcessedByImmediateActivation(IActivationContext context)
		{
			if (!StackIsSmall())
			{
				return false;
			}
			if (!context.Depth().RequiresActivation())
			{
				return true;
			}
			ObjectReference @ref = context.Transaction().ReferenceForObject(context.TargetObject
				());
			if (@ref == null)
			{
				return false;
			}
			if (HandledInCurrentTopLevelCall(@ref))
			{
				return true;
			}
			FlagAsHandled(@ref);
			IncStackDepth();
			try
			{
				@ref.ActivateInternal(context);
			}
			finally
			{
				DecStackDepth();
			}
			return true;
		}
Exemple #5
0
		public void StillToActivate(IActivationContext context)
		{
			// TODO: We don't want the simple classes to search the hc_tree
			// Kick them out here.
			//		if (a_object != null) {
			//			Class clazz = a_object.getClass();
			//			if(! clazz.isPrimitive()){
			if (ProcessedByImmediateActivation(context))
			{
				return;
			}
			_stillToActivate = StillTo1(context.Transaction(), _stillToActivate, context.TargetObject
				(), context.Depth());
		}
Exemple #6
0
 public virtual void CascadeActivation(IActivationContext context)
 {
     if (!ObjectCanActivate(context.Transaction(), context.TargetObject()))
     {
         return;
     }
     TraverseAllAspects(new _ITraverseAspectCommand_162(context));
 }
Exemple #7
0
		private void ReadForActivation(IActivationContext context)
		{
			Read(context.Transaction(), null, context.TargetObject(), context.Depth(), Const4
				.AddMembersToIdTreeOnly, false);
		}
Exemple #8
0
 private void ReadForActivation(IActivationContext context)
 {
     Read(context.Transaction(), null, context.TargetObject(), context.Depth(), Const4
          .AddMembersToIdTreeOnly, false);
 }
		protected object CascadingTarget(IActivationContext context)
		{
			if (context.Depth().Mode().IsDeactivate())
			{
				if (null == _reflectField)
				{
					return null;
				}
				return FieldAccessor().Get(_reflectField, context.TargetObject());
			}
			return GetOrCreate(context.Transaction(), context.TargetObject());
		}