public static IContextItem GetItemByContentType(this IContextCollection collection, Guid contentTypeId)
        {
            var item = collection.Find(
                c => c.ContentTypeId == contentTypeId && string.IsNullOrEmpty(c.Relationship));

            return(item);
        }
        public static IContextItem GetItemByTypeName(this IContextCollection collection, string typeName)
        {
            var item = collection.Find(
                c => c.TypeName.Equals(typeName, StringComparison.InvariantCultureIgnoreCase));

            return(item);
        }
Ejemplo n.º 3
0
 public ChannelHandlerContext(IChannel channel, IContextCollection contextCollection)
 {
     _channel = channel;
     _contextCollection = contextCollection;
 }
Ejemplo n.º 4
0
 public ContextCache(IReadOnlyContextCollection parent)
 {
     _collection = new EmptyContextCollection(parent);
 }
Ejemplo n.º 5
0
 public ContextCache()
 {
     _collection = EmptyContextCollection.Shared.Empty;
 }