/// <exception cref="System.IO.IOException"/>
        internal IPortable ReadAndInitialize(IBufferObjectDataInput @in, int factoryId, int classId)
        {
            IPortable       p = Read(@in, factoryId, classId);
            IManagedContext managedContext = context.GetManagedContext();

            return(managedContext != null ? (IPortable)managedContext.Initialize(p) : p);
        }
예제 #2
0
 public object Initialize(object obj)
 {
     if (obj is IHazelcastInstanceAware)
     {
         ((IHazelcastInstanceAware)obj).SetHazelcastInstance(instance);
     }
     if (hasExternalContext)
     {
         obj = externalContext.Initialize(obj);
     }
     return(obj);
 }
예제 #3
0
        public object Initialize(object obj)
        {
            var aware = obj as IHazelcastInstanceAware;

            if (aware != null)
            {
                aware.SetHazelcastInstance(_instance);
            }
            if (_hasExternalContext)
            {
                obj = _externalContext.Initialize(obj);
            }
            return(obj);
        }