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 BeatsToProto(beats *tb.TickerBeats) *v1.TradeBeats
- func DealToProto(a *dea.Deal) *v1.Deal
- func DealsToProto(deals []*dea.Deal) []*v1.Deal
- func OrderToProto(a *ord.Order) *v1.Order
- func OrdersToProto(orders []*ord.Order) []*v1.Order
- func PositionToProto(a *pos.Position) *v1.Position
- func PositionsToProto(positions []*pos.Position) []*v1.Position
- func ProtoToAccount(a *v1.Account) *acc.Account
- func ProtoToAccountInfo(a *v1.Account) *acc.AccountInfo
- func ProtoToDeal(a *v1.Deal) *dea.Deal
- func ProtoToOrder(a *v1.Order) *ord.Order
- func ProtoToPosition(a *v1.Position) *pos.Position
- func ProtoToTradeRequest(accountID, creationOrder int64, a *v1.TradeRequest) *model.TradeRequest
- func ProtoToTradeResult(accountID, creationOrder int64, a *v1.TradeResult) *model.TradeResult
- func ProtoToTradeTransaction(accountID, creationOrder int64, a *v1.TradeTransaction) *model.TradeTransaction
- func SignalToProto(s *sig.Signal) *v1.Signal
- func TradeRequestToProto(a *model.TradeRequest) *v1.TradeRequest
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BeatsToProto ¶ added in v0.12.0
func BeatsToProto(beats *tb.TickerBeats) *v1.TradeBeats
BeatsToProto transform tb.TickerBeats int v1.TickerBeats TODO: try to use proto.Marshal and Unmarshal
func DealToProto ¶
DealToProto transform an dea.Deal model into an proto v1.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 *v1.Account) *acc.AccountInfo
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 *v1.TradeRequest) *model.TradeRequest
ProtoToTradeTransaction transform an proto to an TradeTransaction model
func ProtoToTradeResult ¶
func ProtoToTradeResult(accountID, creationOrder int64, a *v1.TradeResult) *model.TradeResult
ProtoToTradeTransaction transform an proto to an TradeTransaction model
func ProtoToTradeTransaction ¶
func ProtoToTradeTransaction(accountID, creationOrder int64, a *v1.TradeTransaction) *model.TradeTransaction
ProtoToTradeTransaction transform an proto to an TradeTransaction model
func SignalToProto ¶ added in v0.9.2
SignalToProto transform sig.Signal into v1.Signal TODO: try to use proto.Marshal and Unmarshal
func TradeRequestToProto ¶ added in v0.13.3
func TradeRequestToProto(a *model.TradeRequest) *v1.TradeRequest
ProtoToTradeTransaction transform an proto to an TradeTransaction model
Types ¶
This section is empty.