Пример #1
0
        public TestPage() {
            this.InitializeComponent();

            this.api = APIConnector.GetInstance(new Uri("https://seafile.bruegner.com"));

            this.api.AllowUntrustedConnections = true;
        }
Пример #2
0
        public static APIConnector GetInstance(Uri baseUri) {
            if(Instances.ContainsKey(baseUri)) {
                return Instances[baseUri];
            }
            else {
                var instance = new APIConnector(baseUri);

                Instances.Add(baseUri, instance);

                return instance;
            }
        }