示例#1
0
		private void DoResponse(string format, IControllerBridge bridge)
		{
			Responder hander = new Responder(bridge, bridge.ControllerAction);
			hander.Format = format;
			_renderers[format](hander);

			MimeType usedType = _mimeTypes.Where(mime => mime.Symbol == format).First();
			bridge.SetResponseType(usedType);
		}
示例#2
0
        private void DoResponse(string format, IControllerBridge bridge)
        {
            Responder hander = new Responder(bridge, bridge.ControllerAction);

            hander.Format = format;
            _renderers[format](hander);

            MimeType usedType = _mimeTypes.Where(mime => mime.Symbol == format).First();

            bridge.SetResponseType(usedType);
        }
示例#3
0
        private void DoResponse(string format, IControllerBridge bridge)
        {
            Responder hander = new Responder(bridge, bridge.ControllerAction);
            hander.Format = format;
            _renderers[format](hander);

            MimeTypes types = new MimeTypes();
            types.RegisterBuiltinTypes();

//            MimeType usedType = types.Where(mime => mime.Symbol == format).First();
            MimeType usedType = types.FindAll(delegate(MimeType mime) { return mime.Symbol == format; })[0];
            bridge.SetResponseType(usedType);
        }
示例#4
0
        private void DoResponse(string format, IControllerBridge bridge)
        {
            Responder hander = new Responder(bridge, bridge.ControllerAction);

            hander.Format = format;
            _renderers[format](hander);

            MimeTypes types = new MimeTypes();

            types.RegisterBuiltinTypes();

//            MimeType usedType = types.Where(mime => mime.Symbol == format).First();
            MimeType usedType = types.FindAll(delegate(MimeType mime) { return(mime.Symbol == format); })[0];

            bridge.SetResponseType(usedType);
        }