Skip to content

Commit

Permalink
remove index value from toString()
Browse files Browse the repository at this point in the history
fix date format in toString()
  • Loading branch information
kosyloa committed Nov 7, 2023
1 parent 4d18b81 commit 309890a
Show file tree
Hide file tree
Showing 8 changed files with 10 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@
isEnabled = "NO">
</CommandLineArgument>
<CommandLineArgument
argument = "Connect demo.dxfeed.com:7300 quote AAPL -f 2012-05-26-14:15:00"
argument = "Connect demo.dxfeed.com:7300 candle AAPL -f 2012-05-26-14:15:00"
isEnabled = "NO">
</CommandLineArgument>
<CommandLineArgument
Expand All @@ -93,6 +93,10 @@
</CommandLineArgument>
<CommandLineArgument
argument = "DuMp tapeK2.tape[speed=max] -t ios_tapeK2.tape -q"
isEnabled = "NO">
</CommandLineArgument>
<CommandLineArgument
argument = "Connect demo.dxfeed.com:7300 candle AAPL{=2d} -f 0"
isEnabled = "YES">
</CommandLineArgument>
<CommandLineArgument
Expand Down
3 changes: 1 addition & 2 deletions DXFeedFramework/Events/Market/Candles/Candle.swift
Original file line number Diff line number Diff line change
Expand Up @@ -136,9 +136,8 @@ extension Candle {
func baseFieldsToString() -> String {
return """
\(eventSymbol), \
eventTime=" + \(TimeUtil.toLocalDateString(millis: eventTime)), \
eventTime=\(TimeUtil.toLocalDateString(millis: eventTime)), \
eventFlags=\(eventFlags.toHexString()), \
index=\(index.toHexString()), \
time=\(TimeUtil.toLocalDateString(millis: time)), \
sequence=\(getSequence()), \
count=\(count), \
Expand Down
1 change: 0 additions & 1 deletion DXFeedFramework/Events/Market/Greeks.swift
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,6 @@ extension Greeks {
Greeks{\(eventSymbol), \
eventTime=\(TimeUtil.toLocalDateString(millis: eventTime)), \
eventFlags=\(eventFlags.toHexString()), \
index=\(index.toHexString()), \
time=\(TimeUtil.toLocalDateString(millis: time)), \
sequence=\(self.getSequence()), \
price=\(price), \
Expand Down
1 change: 0 additions & 1 deletion DXFeedFramework/Events/Market/TheoPrice.swift
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,6 @@ extension TheoPrice {
TheoPrice{\(eventSymbol) \
eventTime=\(TimeUtil.toLocalDateString(millis: eventTime)), \
eventFlags=\(eventFlags.toHexString()), \
index=\(index.toHexString()), \
time=\(TimeUtil.toLocalDateString(millis: time)), \
sequence=\(self.getSequence()), \
price=\(price) \
Expand Down
1 change: 0 additions & 1 deletion DXFeedFramework/Events/Market/TimeAndSale.swift
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,6 @@ extension TimeAndSale {
TimeAndSale{\(eventSymbol), \
eventTime=\(TimeUtil.toLocalDateString(millis: eventTime)), \
eventFlags=\(eventFlags.toHexString()), \
index=\(index.toHexString()), \
time=\(TimeUtil.toLocalDateString(millis: time)), \
timeNanoPart=\(timeNanoPart), \
sequence=\(getSequence()), \
Expand Down
1 change: 0 additions & 1 deletion DXFeedFramework/Events/Market/Underlying.swift
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,6 @@ extension Underlying {
Underlying{"\(eventSymbol) \
eventTime=\(TimeUtil.toLocalDateString(millis: eventTime)), \
eventFlags=\(eventFlags.toHexString()), \
index=\(index.toHexString()), \
time=\(TimeUtil.toLocalDateString(millis: time)), \
sequence=\(self.getSequence()), \
volatility=\(volatility), \
Expand Down
2 changes: 1 addition & 1 deletion DXFeedFramework/Utils/TimeUtil.swift
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public class TimeUtil {
}()
static let dateFormatterWithMillis = {
let formatter = DateFormatter()
formatter.dateFormat = "yyyyMMdd-HHmmss.SSS"
formatter.dateFormat = "yyyyMMdd-HHmmss.SSSZZZZZ"
return formatter
}()

Expand Down
3 changes: 3 additions & 0 deletions Samples/Tools/SubscriptionUtils.swift
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,9 @@ Create subscription to \(address) for \(types):\(symbols) with properties:\(prop
let timeSubscriptionSymbols = symbols.map { symbol in
TimeSeriesSubscriptionSymbol(symbol: symbol, date: date)
}
print(symbols)
print(date)
print(timeSubscriptionSymbols)
try? subscription?.addSymbols(timeSubscriptionSymbols)
} else if source != nil {
if let source = try? OrderSource.valueOf(name: source!) {
Expand Down

0 comments on commit 309890a

Please sign in to comment.