Esempio n. 1
0
        public static Conformance.ConformanceRestComponent AddRestComponent(this Conformance conformance, Boolean isServer, String documentation = null)
        {
            var server = new Conformance.ConformanceRestComponent();
            server.Mode = (isServer) ? Conformance.RestfulConformanceMode.Server : Conformance.RestfulConformanceMode.Client;

            if (documentation != null)
            {
                server.Documentation = documentation;
            }
            conformance.Rest.Add(server);
            return server;
        }
Esempio n. 2
0
        public static Conformance.ConformanceRestComponent AddRestComponent(this Conformance conformance, Boolean isServer, String documentation = null, String mailbox = null)
        {
            var server = new Conformance.ConformanceRestComponent();
            server.Mode = (isServer) ? Conformance.RestfulConformanceMode.Server : Conformance.RestfulConformanceMode.Client;

            if (documentation != null)
            {
                server.Documentation = documentation;
            }

            if (mailbox != null)
            {
                var listmailbox = (List<String>)server.DocumentMailbox;
                listmailbox.Add(mailbox);
                server.DocumentMailbox = listmailbox;

            }
            conformance.Rest.Add(server);
            return server;
        }