예제 #1
0
        /// <summary>
        /// Constructor.
        /// </summary>
        /// <param name="typeId">Type ID.</param>
        /// <param name="typeName">Type name.</param>
        /// <param name="affKeyFieldName">Affinity key field name.</param>
        public PortableMetadataHolder(int typeId, string typeName, string affKeyFieldName)
        {
            _typeId          = typeId;
            _typeName        = typeName;
            _affKeyFieldName = affKeyFieldName;

            _emptyMeta = new PortableMetadataImpl(typeId, typeName, null, affKeyFieldName);
        }
        /// <summary>
        /// Constructor.
        /// </summary>
        /// <param name="typeId">Type ID.</param>
        /// <param name="typeName">Type name.</param>
        /// <param name="affKeyFieldName">Affinity key field name.</param>
        public PortableMetadataHolder(int typeId, string typeName, string affKeyFieldName)
        {
            _typeId = typeId;
            _typeName = typeName;
            _affKeyFieldName = affKeyFieldName;

            _emptyMeta = new PortableMetadataImpl(typeId, typeName, null, affKeyFieldName);
        }
예제 #3
0
            public void OnEvent(IEnumerable <ICacheEntryEvent <int, IPortableObject> > evts)
            {
                foreach (ICacheEntryEvent <int, IPortableObject> evt in evts)
                {
                    IPortableObject val = evt.Value;

                    IPortableMetadata meta = val.Metadata();

                    Assert.AreEqual(typeof(PortableEntry).Name, meta.TypeName);
                }

                countDown.Signal();
            }
예제 #4
0
        /// <summary>
        /// Gets metadata for the given type ID.
        /// </summary>
        /// <param name="typeId">Type ID.</param>
        /// <returns>Metadata or null.</returns>
        public IPortableMetadata Metadata(int typeId)
        {
            if (Ignite != null)
            {
                IPortableMetadata meta = Ignite.Metadata(typeId);

                if (meta != null)
                {
                    return(meta);
                }
            }

            return(PortableMetadataImpl.EmptyMeta);
        }