Skip to main content

ids_apis/
master_sync.v1.etf.rs

1// @generated
2// This file is @generated by prost-build.
3#[allow(clippy::derive_partial_eq_without_eq)]
4#[derive(Clone, PartialEq, ::prost::Message)]
5pub struct Etf {
6    /// ETF ID
7    #[prost(uint64, tag="1")]
8    pub id: u64,
9    /// ETF 심볼 (ISIN 코드)
10    #[prost(string, tag="2")]
11    pub symbol: ::prost::alloc::string::String,
12    /// ETF 코드
13    #[prost(string, tag="3")]
14    pub code: ::prost::alloc::string::String,
15    /// ETF 이름
16    #[prost(string, tag="4")]
17    pub name: ::prost::alloc::string::String,
18    /// 마지막 가격
19    #[prost(string, tag="5")]
20    pub prev_close: ::prost::alloc::string::String,
21    #[prost(string, tag="6")]
22    pub last_price: ::prost::alloc::string::String,
23    #[prost(string, tag="7")]
24    pub prev_close_nav: ::prost::alloc::string::String,
25    #[prost(string, tag="8")]
26    pub last_ask_inav: ::prost::alloc::string::String,
27    #[prost(string, tag="9")]
28    pub last_bid_inav: ::prost::alloc::string::String,
29    /// PDF 구성 종목 목록
30    #[prost(map="string, message", tag="10")]
31    pub constituents: ::std::collections::HashMap<::prost::alloc::string::String, EtfPdfConstituent>,
32    /// 설정 단위
33    #[prost(int64, tag="11")]
34    pub creation_unit: i64,
35    /// 복제 방법
36    #[prost(enumeration="ReplicationMethod", tag="12")]
37    pub replication_method: i32,
38    /// Tick 크기 (원 단위, i64)
39    #[prost(int64, tag="13")]
40    pub tick_size: i64,
41    /// Tick 크기 (원 단위, i64)
42    #[prost(int64, tag="14")]
43    pub listed_quantity: i64,
44    #[prost(float, tag="15")]
45    pub leverage: f32,
46    #[prost(bool, tag="16")]
47    pub tradable: bool,
48    #[prost(bool, tag="17")]
49    pub short_sellable: bool,
50    #[prost(bool, tag="23")]
51    pub cash_creditable: bool,
52    #[prost(int64, tag="24")]
53    pub cash_creation_amount: i64,
54}
55#[allow(clippy::derive_partial_eq_without_eq)]
56#[derive(Clone, PartialEq, ::prost::Message)]
57pub struct EtfConstituent {
58    #[prost(oneof="etf_constituent::ConstituentType", tags="1, 2, 3")]
59    pub constituent_type: ::core::option::Option<etf_constituent::ConstituentType>,
60}
61/// Nested message and enum types in `EtfConstituent`.
62pub mod etf_constituent {
63    #[allow(clippy::derive_partial_eq_without_eq)]
64#[derive(Clone, PartialEq, ::prost::Oneof)]
65    pub enum ConstituentType {
66        #[prost(message, tag="1")]
67        Stock(super::StockConstituent),
68        #[prost(message, tag="2")]
69        Futures(super::FuturesConstituent),
70        #[prost(message, tag="3")]
71        Cash(super::CashConstituent),
72    }
73}
74#[allow(clippy::derive_partial_eq_without_eq)]
75#[derive(Clone, PartialEq, ::prost::Message)]
76pub struct StockConstituent {
77    #[prost(string, tag="1")]
78    pub symbol: ::prost::alloc::string::String,
79    #[prost(string, tag="2")]
80    pub prev_close: ::prost::alloc::string::String,
81    #[prost(string, tag="3")]
82    pub last_price: ::prost::alloc::string::String,
83    #[prost(int64, tag="4")]
84    pub quantity: i64,
85    #[prost(int64, tag="5")]
86    pub last_valuation: i64,
87    #[prost(int64, tag="6")]
88    pub notional_amount: i64,
89    #[prost(uint32, tag="7")]
90    pub num_members: u32,
91}
92#[allow(clippy::derive_partial_eq_without_eq)]
93#[derive(Clone, PartialEq, ::prost::Message)]
94pub struct FuturesConstituent {
95    #[prost(string, tag="1")]
96    pub symbol: ::prost::alloc::string::String,
97    #[prost(string, tag="2")]
98    pub prev_close: ::prost::alloc::string::String,
99    #[prost(string, tag="3")]
100    pub last_price: ::prost::alloc::string::String,
101    #[prost(float, tag="4")]
102    pub quantity: f32,
103    #[prost(double, tag="5")]
104    pub multiple: f64,
105    #[prost(int64, tag="6")]
106    pub last_valuation: i64,
107    #[prost(int64, tag="7")]
108    pub notional_amount: i64,
109    #[prost(uint32, tag="8")]
110    pub num_members: u32,
111}
112#[allow(clippy::derive_partial_eq_without_eq)]
113#[derive(Clone, PartialEq, ::prost::Message)]
114pub struct CashConstituent {
115    #[prost(string, tag="1")]
116    pub symbol: ::prost::alloc::string::String,
117    #[prost(int64, tag="2")]
118    pub prev_valuation: i64,
119    #[prost(uint32, tag="3")]
120    pub num_members: u32,
121}
122/// PDF 구성 종목
123#[allow(clippy::derive_partial_eq_without_eq)]
124#[derive(Clone, PartialEq, ::prost::Message)]
125pub struct EtfPdfConstituent {
126    /// 종목 코드
127    ///
128    /// symbol
129    #[prost(string, tag="1")]
130    pub symbol: ::prost::alloc::string::String,
131    /// 종목명
132    #[prost(string, tag="2")]
133    pub name: ::prost::alloc::string::String,
134    /// 상품 타입
135    #[prost(enumeration="ProductType", tag="3")]
136    pub product_type: i32,
137    /// 구성 수량 (선물 숏의 경우 음수)
138    #[prost(int64, tag="4")]
139    pub quantity: i64,
140}
141// ========== Request/Response Messages ==========
142
143/// GetEtf
144#[allow(clippy::derive_partial_eq_without_eq)]
145#[derive(Clone, PartialEq, ::prost::Message)]
146pub struct GetEtfRequest {
147    #[prost(string, tag="1")]
148    pub etf: ::prost::alloc::string::String,
149}
150/// ListEtfs
151#[allow(clippy::derive_partial_eq_without_eq)]
152#[derive(Clone, PartialEq, ::prost::Message)]
153pub struct ListEtfsRequest {
154    /// 페이지 크기 (optional)
155    #[prost(uint32, optional, tag="1")]
156    pub page_size: ::core::option::Option<u32>,
157    /// 페이지 토큰 (optional, for pagination)
158    #[prost(string, optional, tag="2")]
159    pub page_token: ::core::option::Option<::prost::alloc::string::String>,
160    /// 필터링 조건 (optional, AIP-160)
161    #[prost(string, tag="3")]
162    pub filter: ::prost::alloc::string::String,
163}
164#[allow(clippy::derive_partial_eq_without_eq)]
165#[derive(Clone, PartialEq, ::prost::Message)]
166pub struct ListEtfsResponse {
167    /// ETF 목록
168    #[prost(message, repeated, tag="1")]
169    pub etfs: ::prost::alloc::vec::Vec<Etf>,
170    /// 다음 페이지 토큰
171    #[prost(string, tag="2")]
172    pub next_page_token: ::prost::alloc::string::String,
173}
174/// 상품 타입
175#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
176#[repr(i32)]
177pub enum ProductType {
178    Unspecified = 0,
179    Stock = 1,
180    Futures = 2,
181    Etf = 3,
182    Cash = 4,
183}
184impl ProductType {
185    /// String value of the enum field names used in the ProtoBuf definition.
186    ///
187    /// The values are not transformed in any way and thus are considered stable
188    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
189    pub fn as_str_name(&self) -> &'static str {
190        match self {
191            ProductType::Unspecified => "PRODUCT_TYPE_UNSPECIFIED",
192            ProductType::Stock => "PRODUCT_TYPE_STOCK",
193            ProductType::Futures => "PRODUCT_TYPE_FUTURES",
194            ProductType::Etf => "PRODUCT_TYPE_ETF",
195            ProductType::Cash => "PRODUCT_TYPE_CASH",
196        }
197    }
198    /// Creates an enum from field names used in the ProtoBuf definition.
199    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
200        match value {
201            "PRODUCT_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
202            "PRODUCT_TYPE_STOCK" => Some(Self::Stock),
203            "PRODUCT_TYPE_FUTURES" => Some(Self::Futures),
204            "PRODUCT_TYPE_ETF" => Some(Self::Etf),
205            "PRODUCT_TYPE_CASH" => Some(Self::Cash),
206            _ => None,
207        }
208    }
209}
210/// 복제 방법
211#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
212#[repr(i32)]
213pub enum ReplicationMethod {
214    Unspecified = 0,
215    Active = 1,
216    Physical = 2,
217    Synthetic = 3,
218}
219impl ReplicationMethod {
220    /// String value of the enum field names used in the ProtoBuf definition.
221    ///
222    /// The values are not transformed in any way and thus are considered stable
223    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
224    pub fn as_str_name(&self) -> &'static str {
225        match self {
226            ReplicationMethod::Unspecified => "REPLICATION_METHOD_UNSPECIFIED",
227            ReplicationMethod::Active => "REPLICATION_METHOD_ACTIVE",
228            ReplicationMethod::Physical => "REPLICATION_METHOD_PHYSICAL",
229            ReplicationMethod::Synthetic => "REPLICATION_METHOD_SYNTHETIC",
230        }
231    }
232    /// Creates an enum from field names used in the ProtoBuf definition.
233    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
234        match value {
235            "REPLICATION_METHOD_UNSPECIFIED" => Some(Self::Unspecified),
236            "REPLICATION_METHOD_ACTIVE" => Some(Self::Active),
237            "REPLICATION_METHOD_PHYSICAL" => Some(Self::Physical),
238            "REPLICATION_METHOD_SYNTHETIC" => Some(Self::Synthetic),
239            _ => None,
240        }
241    }
242}
243include!("master_sync.v1.etf.tonic.rs");
244include!("master_sync.v1.etf.serde.rs");
245// @@protoc_insertion_point(module)