﻿<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type='text/css' href='https://stocksharp.ru/css/style.css'?>
<?xml-stylesheet type='text/css' href='https://stocksharp.ru/css/bbeditor.css'?>
<feed xmlns="http://www.w3.org/2005/Atom">
  <title type="html">Не понимаю работу метода FinamHistorySource.Refresh</title>
  <id>~/topic/8281/ne-ponimayu-rabotu-metoda-finamhistorysource_refresh/</id>
  <rights type="text">Copyright @ StockSharp Platform LLC 2010 - 2025</rights>
  <updated>2026-06-14T21:54:30Z</updated>
  <logo>https://stocksharp.ru/images/logo.png</logo>
  <link href="https://stocksharp.ru/handlers/atom.ashx?category=topic&amp;id=8281" rel="self" type="application/rss+xml" />
  <entry>
    <id>https://stocksharp.ru/posts/m/40037/</id>
    <title type="text">Security security = new Security ; </title>
    <published>2017-05-30T12:54:11Z</published>
    <updated>2017-05-30T12:54:11Z</updated>
    <author>
      <name>Support</name>
      <uri>https://stocksharp.ru/users/97869/</uri>
      <email>info@stocksharp.ru</email>
    </author>
    <content type="html">&lt;p Type="SecurityTypes.Future"&gt;Security security = new Security ;&lt;/p&gt;
</content>
    <rights type="html">Copyright @ StockSharp Platform LLC 2010 - 2025</rights>
  </entry>
  <entry>
    <id>https://stocksharp.ru/posts/m/40028/</id>
    <title type="text">Всё работает, просто хочу увеличить эффективность загрузки. Думал, как фильтр (criteria) может помоч...</title>
    <published>2017-05-29T13:12:04Z</published>
    <updated>2017-05-29T13:12:04Z</updated>
    <author>
      <name>Дмитрий_</name>
      <uri>https://stocksharp.ru/users/62269/</uri>
      <email>info@stocksharp.ru</email>
    </author>
    <content type="html">&lt;p&gt;Всё работает, просто хочу увеличить эффективность загрузки. Думал, как фильтр (criteria) может помочь с этим?
Покажите пожалуйста на примере, как сделать так, чтобы в securityStorage сохранились, допустим, только фьючерсы FORTS.&lt;/p&gt;
</content>
    <rights type="html">Copyright @ StockSharp Platform LLC 2010 - 2025</rights>
  </entry>
  <entry>
    <id>https://stocksharp.ru/posts/m/40027/</id>
    <title type="text">Функция FinamHistorySource.Refresh неправильно работает или приводит к возникновению ошибки? </title>
    <published>2017-05-29T12:51:00Z</published>
    <updated>2017-05-29T12:51:00Z</updated>
    <author>
      <name>Support</name>
      <uri>https://stocksharp.ru/users/97869/</uri>
      <email>info@stocksharp.ru</email>
    </author>
    <content type="html">&lt;p&gt;Функция FinamHistorySource.Refresh неправильно работает или приводит к возникновению ошибки?&lt;/p&gt;
</content>
    <rights type="html">Copyright @ StockSharp Platform LLC 2010 - 2025</rights>
  </entry>
  <entry>
    <id>https://stocksharp.ru/posts/m/40015/</id>
    <title type="text">Имел ввиду, что используя фильтр Security security = new Security { Id = &amp;quot;SBER@TQBR&amp;quot;, Board = Exchan...</title>
    <published>2017-05-26T19:23:09Z</published>
    <updated>2017-05-26T19:23:09Z</updated>
    <author>
      <name>Дмитрий_</name>
      <uri>https://stocksharp.ru/users/62269/</uri>
      <email>info@stocksharp.ru</email>
    </author>
    <content type="html">&lt;ol start="2"&gt;
&lt;li&gt;Имел ввиду, что используя фильтр
Security security = new Security { Id = &amp;quot;SBER@TQBR&amp;quot;, Board = ExchangeBoard.Micex };
в securityStorage сохранятся все 14787 инструментов, корме SBER@TQBR. Поэтому &amp;quot;Зачем отфильтровывать 1 инструмент? &amp;quot;
Сейчас прояснилось, что в securityStorage сохранится только SBER@TQBR&lt;/li&gt;
&lt;li&gt;Security security = new Security ; - данный фильтр не оставляет в securityStorage инструменты с Id = &amp;quot;@TQBR&amp;quot;.&lt;/li&gt;
&lt;/ol&gt;
</content>
    <rights type="html">Copyright @ StockSharp Platform LLC 2010 - 2025</rights>
  </entry>
  <entry>
    <id>https://stocksharp.ru/posts/m/40014/</id>
    <title type="text">фильтр только по типу инструмента вопрос не понятен securityStorage см. п1. Security security = new ...</title>
    <published>2017-05-26T16:25:26Z</published>
    <updated>2017-05-26T16:25:26Z</updated>
    <author>
      <name>Support</name>
      <uri>https://stocksharp.ru/users/97869/</uri>
      <email>info@stocksharp.ru</email>
    </author>
    <content type="html">&lt;ol&gt;
&lt;li&gt;фильтр только по типу инструмента&lt;/li&gt;
&lt;li&gt;вопрос не понятен&lt;/li&gt;
&lt;li&gt;securityStorage&lt;/li&gt;
&lt;li&gt;см. п1.&lt;/li&gt;
&lt;li&gt;Security security = new Security ;&lt;/li&gt;
&lt;/ol&gt;
</content>
    <rights type="html">Copyright @ StockSharp Platform LLC 2010 - 2025</rights>
  </entry>
  <entry>
    <id>https://stocksharp.ru/posts/m/40013/</id>
    <title type="text">&amp;quot;2) Работает как поиск подстроки, т.е. можно использовать &amp;quot;@TQBS&amp;quot; &amp;quot; - покажите пожалуйста на примере...</title>
    <published>2017-05-25T17:17:55Z</published>
    <updated>2017-05-25T17:22:48Z</updated>
    <author>
      <name>Дмитрий_</name>
      <uri>https://stocksharp.ru/users/62269/</uri>
      <email>info@stocksharp.ru</email>
    </author>
    <content type="html">&lt;ol start="5"&gt;
&lt;li&gt;&amp;quot;2) Работает как поиск подстроки, т.е. можно использовать &amp;quot;@TQBS&amp;quot; &amp;quot; - покажите пожалуйста на примере&lt;/li&gt;
&lt;/ol&gt;
</content>
    <rights type="html">Copyright @ StockSharp Platform LLC 2010 - 2025</rights>
  </entry>
  <entry>
    <id>https://stocksharp.ru/posts/m/40012/</id>
    <title type="text">Какая практическая ценность criteria (зачем он нужен), если в любом случае будут загружены все инстр...</title>
    <published>2017-05-25T17:17:54Z</published>
    <updated>2017-05-25T17:17:54Z</updated>
    <author>
      <name>Дмитрий_</name>
      <uri>https://stocksharp.ru/users/62269/</uri>
      <email>info@stocksharp.ru</email>
    </author>
    <content type="html">&lt;ol&gt;
&lt;li&gt;Какая практическая ценность criteria (зачем он нужен), если в любом случае будут загружены все инструменты? (покажите на примере)&lt;/li&gt;
&lt;li&gt;Зачем отфильтровывать 1 инструмент?&lt;/li&gt;
&lt;li&gt;Куда сохраняются отфильтроавнные инструменты?&lt;/li&gt;
&lt;li&gt;В чём разница между:
Security security = new Security { Id = &amp;quot;SBER@TQBR&amp;quot;, Board = ExchangeBoard.Micex };
FinamHistorySource.Refresh(securityStorage, security, s =&amp;gt; { isCanceled = UpdateLoadingProgressBar(s, security, ++step); }, () =&amp;gt; isCanceled);
и
Security security = new Security ();
FinamHistorySource.Refresh(securityStorage, security, s =&amp;gt; { isCanceled = UpdateLoadingProgressBar(s, security, ++step); }, () =&amp;gt; isCanceled);
если потом, я всё равно могу получить данные
var dataSecurity = historySource.GetCandles(security, timeFrame, from, to);?&lt;/li&gt;
&lt;/ol&gt;
</content>
    <rights type="html">Copyright @ StockSharp Platform LLC 2010 - 2025</rights>
  </entry>
  <entry>
    <id>https://stocksharp.ru/posts/m/40008/</id>
    <title type="text">В любом случае будут загружены все инструменты, т.к. criteria - это фильтр.. Работает как поиск подс...</title>
    <published>2017-05-25T13:53:41Z</published>
    <updated>2017-05-25T13:53:41Z</updated>
    <author>
      <name>Support</name>
      <uri>https://stocksharp.ru/users/97869/</uri>
      <email>info@stocksharp.ru</email>
    </author>
    <content type="html">&lt;ol&gt;
&lt;li&gt;В любом случае будут загружены все инструменты, т.к. criteria - это фильтр..&lt;/li&gt;
&lt;li&gt;Работает как поиск подстроки, т.е. можно использовать  &amp;quot;@TQBS&amp;quot;&lt;/li&gt;
&lt;li&gt;Что бы прервать загрузку в момент получения нужного инструмента используйте делегат isCanceled&lt;/li&gt;
&lt;/ol&gt;
</content>
    <rights type="html">Copyright @ StockSharp Platform LLC 2010 - 2025</rights>
  </entry>
  <entry>
    <id>https://stocksharp.ru/posts/m/40003/</id>
    <title type="text">Здравствуйте. Его описание: http://doc.stocksharp.ru/html/M_StockSharp_Algo_History_Russian_Finam_Fi...</title>
    <published>2017-05-24T17:53:22Z</published>
    <updated>2017-05-24T17:54:56Z</updated>
    <author>
      <name>Дмитрий_</name>
      <uri>https://stocksharp.ru/users/62269/</uri>
      <email>info@stocksharp.ru</email>
    </author>
    <content type="html">&lt;p&gt;Здравствуйте.&lt;/p&gt;
&lt;p&gt;Его описание:
&lt;a href="http://doc.stocksharp.ru/html/M_StockSharp_Algo_History_Russian_Finam_FinamHistorySource_Refresh.htm"&gt;http://doc.stocksharp.ru/html/M_StockSharp_Algo_History_Russian_Finam_FinamHistorySource_Refresh.htm&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;int step = 0;
Security security = new Security { Id = &amp;quot;SBER@TQBR&amp;quot;, Board = ExchangeBoard.Micex };
При вызове метода FinamHistorySource.Refresh(securityStorage, security, s =&amp;gt; { isCanceled = UpdateLoadingProgressBar(s, security, ++step); }, () =&amp;gt; isCanceled); всегда загружается 14787 инструментов, что занимает приличное время.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;p&gt;Как правильно использовать параметр criteria
(Тип: StockSharp.BusinessEntities.Security Инструмент, поля которого будут использоваться в качестве фильтра.),
чтобы загружался только нужный security?&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Какой параметр criteria использовать для групповой загрузки инструментов (например: GAZP@TQBS, SBER@TQBS и SBERP@TQBS)?&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p Board="ExchangeBoard.Spb"&gt;Если правильно понимаю логику метода:
Допустим
Security security = new Security ;
и FinamHistorySource.Refresh(securityStorage, security, s =&amp;gt; { isCanceled = UpdateLoadingProgressBar(s, security, ++step); }, () =&amp;gt; isCanceled); то перебор (поиск) инструментов будет только среди бумаг, где ExchangeBoard = Spb? На практике, всё равно грузит все 14787 инструментов.&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
</content>
    <rights type="html">Copyright @ StockSharp Platform LLC 2010 - 2025</rights>
  </entry>
</feed>