Documentation ¶
Overview ¶
Copyright 2021 Sander Ruscigno
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2021 Sander Ruscigno ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2021 Sander Ruscigno ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2021 Sander Ruscigno ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2021 Sander Ruscigno ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2021 Sander Ruscigno ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2021 Sander Ruscigno ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Index ¶
- func AccountInfoToProto(a *acc.AccountInfo) *tickerv1.Account
- func AccountToProto(a *acc.Account) *tickerv1.Account
- func AccountsInfoToProto(accounts []*acc.AccountInfo) []*tickerv1.Account
- func AccountsToProto(accounts []*acc.Account) []*tickerv1.Account
- func DealToProto(a *dea.Deal) *tickerv1.Deal
- func DealsToProto(deals []*dea.Deal) []*tickerv1.Deal
- func OrderToProto(a *ord.Order) *tickerv1.Order
- func OrdersToProto(orders []*ord.Order) []*tickerv1.Order
- func PositionToProto(a *pos.Position) *tickerv1.Position
- func PositionsToProto(positions []*pos.Position) []*tickerv1.Position
- func ProtoToAccount(a *tickerv1.Account) *acc.Account
- func ProtoToAccountInfo(a *tickerv1.Account) (*acc.AccountInfo, int64)
- func ProtoToDeal(a *tickerv1.Deal) *dea.Deal
- func ProtoToOrder(a *tickerv1.Order) *ord.Order
- func ProtoToPosition(a *tickerv1.Position) *pos.Position
- func ProtoToTradeRequest(accountID, creationOrder int64, a *tickerv1.TradeRequest) *model.TradeRequest
- func ProtoToTradeResult(accountID, creationOrder int64, a *tickerv1.TradeResult) *model.TradeResult
- func ProtoToTradeTransaction(accountID, creationOrder int64, a *tickerv1.TradeTransaction) *model.TradeTransaction
- func SignalToProto(s *sig.Signal) *tickerv1.Signal
- func TickersToProto(beats *tb.TickerBeats) *tickerv1.TickerBeats
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AccountInfoToProto ¶
func AccountInfoToProto(a *acc.AccountInfo) *tickerv1.Account
AccountInfoToProto transform an account model into an proto account TODO: try to use proto.Marshal and Unmarshal
func AccountToProto ¶
AccountToProto transform an account model into an proto account TODO: try to use proto.Marshal and Unmarshal
func AccountsInfoToProto ¶
func AccountsInfoToProto(accounts []*acc.AccountInfo) []*tickerv1.Account
AccountsInfoToProto transform a list of accounts model into a list of proto accounts TODO: try to use proto.Marshal and Unmarshal
func AccountsToProto ¶
AccountsToProto transform a list of accounts model into a list of proto accounts TODO: try to use proto.Marshal and Unmarshal
func DealToProto ¶
DealToProto transform an dea.Deal model into an proto tickerv1.Deal TODO: try to use proto.Marshal and Unmarshal
func DealsToProto ¶
DealsToProto transform a list of deals model into a list of proto deals TODO: try to use proto.Marshal and Unmarshal
func OrderToProto ¶
OrderToProto transform an order model into an proto order TODO: try to use proto.Marshal and Unmarshal
func OrdersToProto ¶
OrdersToProto transform a list of orders model into a list of proto orders TODO: try to use proto.Marshal and Unmarshal
func PositionToProto ¶
PositionToProto transform an position model into an proto position TODO: try to use proto.Marshal and Unmarshal
func PositionsToProto ¶
PositionsToProto transform a list of positions model into a list of proto positions TODO: try to use proto.Marshal and Unmarshal
func ProtoToAccount ¶
ProtoToAccount transform an proto to an account model TODO: try to use proto.Marshal and Unmarshal
func ProtoToAccountInfo ¶
func ProtoToAccountInfo(a *tickerv1.Account) (*acc.AccountInfo, int64)
ProtoToAccountInfo transform an proto to an account model TODO: try to use proto.Marshal and Unmarshal
func ProtoToDeal ¶
ProtoToDeal transform an proto to an deaount model TODO: try to use proto.Marshal and Unmarshal
func ProtoToOrder ¶
ProtoToOrder transform an proto to an order model TODO: try to use proto.Marshal and Unmarshal
func ProtoToPosition ¶
ProtoToPosition transform an proto to an position model TODO: try to use proto.Marshal and Unmarshal
func ProtoToTradeRequest ¶
func ProtoToTradeRequest(accountID, creationOrder int64, a *tickerv1.TradeRequest) *model.TradeRequest
ProtoToTradeTransaction transform an proto to an TradeTransaction model
func ProtoToTradeResult ¶
func ProtoToTradeResult(accountID, creationOrder int64, a *tickerv1.TradeResult) *model.TradeResult
ProtoToTradeTransaction transform an proto to an TradeTransaction model
func ProtoToTradeTransaction ¶
func ProtoToTradeTransaction(accountID, creationOrder int64, a *tickerv1.TradeTransaction) *model.TradeTransaction
ProtoToTradeTransaction transform an proto to an TradeTransaction model
func SignalToProto ¶ added in v0.9.2
SignalToProto transform sig.Signal into tickerv1.Signal TODO: try to use proto.Marshal and Unmarshal
func TickersToProto ¶ added in v0.9.2
func TickersToProto(beats *tb.TickerBeats) *tickerv1.TickerBeats
TickersToProto transform tb.TickerBeats int tickerv1.TickerBeats TODO: try to use proto.Marshal and Unmarshal
Types ¶
This section is empty.