Ejemplo n.º 1
0
            static public XSS For(
                Method currentMethod,
                IDecodeMetaData <Local, Parameter, Method, Field, Property, Event, Typ, Attribute, Assembly> mdDecoder,
                IDecodeContracts <Local, Parameter, Method, Field, Typ> contractDecoder,
                bool trace = false)
            {
                Contract.Requires(currentMethod != null);

                var x = new XSS();

                x.CurrentMethod       = currentMethod;
                x.mdDecoder           = mdDecoder;
                x.contractDecoder     = contractDecoder;
                x.currentAssembly     = mdDecoder.DeclaringAssembly(currentMethod);
                x.currentAssemblyName = mdDecoder.Name(x.currentAssembly);
                x.Trace = trace;
                return(x);
            }