Caplin FXIntegrationAPI Documentation - Version 3.47.0-2976-15da410

Message Builder Example - ForwardTradeDetails

package com.caplin.examples.fxapi.generated.motif.fx.tradedetails.TradeDetailsTypesDef; 

import java.math.BigInteger;

import com.caplin.generated.motif.fx.tradedetails.TradeDetailsPartsDef;
import com.caplin.generated.motif.fx.tradedetails.TradeDetailsTypesDef;

public class ForwardTradeDetailsExample {
    public static void main(String[] args) {
                    		
		TradeDetailsTypesDef.ForwardTradeDetails forwardTradeDetails =
		TradeDetailsTypesDef.ForwardTradeDetails
			.newBuilder()
			.setCommonTradeDetailsFields(
			TradeDetailsPartsDef.CommonTradeDetailsFields
				.newBuilder()
				.setAccount("Garfields|GARF")
				.setLastActionDateTime("")
				.setOneWayDirection("")
				.setRequestedDateTime(Instant.now())
				.setTOBOUser("client@customer.co.za")
				.setTraderUsername("sales_trader@novobank.co.za")
				.build())
			.setInterventionTradeDetailsFields(
			TradeDetailsPartsDef.InterventionTradeDetailsFields
				.newBuilder()
				.setCompetition(true)
				.setDealable("")
				.setIntervenerUsername("head_trader@novobank.co.za")
				.setInterventionStatus("")
				.setPricingMode("AUTO")
				.setPrimaryReason("This trade exceeds the GFA")
				.setReasons("")
				.setSource("")
				.setTradeRequestID("")
				.setTradeStatus("AWAITING-PRICE")
				.build())
			.setLegTradeDetails(
			TradeDetailsPartsDef.LegTradeDetailsFields
				.newBuilder()
				.setAccount("Garfields|GARF")
				.setAmount("0")
				.setBuySell("")
				.setSettlementDate("")
				.setTenor("1M")
				.build())
			.setNdfLegTradeDetails(
			TradeDetailsPartsDef.NDFLegTradeDetailsFields
				.newBuilder()
				.setFixingDate("20150620")
				.build())
			.setTimeOptionLegTradeDetails(
			TradeDetailsPartsDef.TimeOptionLegTradeDetailsFields
				.newBuilder()
				.setStartDate("20150620")
				.setStartTenor("1W")
				.build())
			.setTradeDetailsFields(
			TradeDetailsPartsDef.TradeDetailsFields
				.newBuilder()
				.setCurrencyPair("")
				.setDealtCurrency("")
				.setTradingType("")
				.build())
			.build();
            
    }
}