首页 > 其他分享 >fix协议介绍16-查询叮当(quote)

fix协议介绍16-查询叮当(quote)

时间:2023-01-01 14:00:32浏览次数:84  
标签:16 quote fix private add Tag void new public


FIX.5.0SP2 Message

Quote [type 'S']

<Quot>



The Quote message is used as the response to a Quote Request or a Quote Response message in both indicative, tradeable, and restricted tradeable quoting markets.




Added  FIX.4.0

Expand Components | Collapse Components

 

Field or Component

Field Name

FIXML name

Req'd

Comments

Depr.


Component

StandardHeader

BaseHeader


MsgType = S

 


​131​

​QuoteReqID​

@ReqID

 

Required when quote is in response to a Quote Request message

 


​117​

​QuoteID​

@QID


 

 


​1166​

​QuoteMsgID​

@QtMsgID

 

Optionally used to supply a message identifier for a quote.

 


​693​

​QuoteRespID​

@RspID

 

Required when responding to the Quote Response message. The counterparty specified ID of the Quote Response message.

 


​537​

​QuoteType​

@Typ

 

Quote Type

If not specified, the default is an indicative quote

 


​1171​

​PrivateQuote​

@PrvtQt

 

Used to indicate whether a private negotiation is requested or if the response should be public. Only relevant in markets supporting both Private and Public quotes. If field is not provided in message, the model used must be bilaterally agreed.

 


Component

QuotQualGrp

QuotQual

 

 

 


​301​

​QuoteResponseLevel​

@RspLvl

 

Level of Response requested from receiver of quote messages.

 


Component

Parties

Pty

 

Insert here the set of "Parties" (firm identification) fields defined in "Common Components of Application Messages"

 


​336​

​TradingSessionID​

@SesID

 

 

 


​625​

​TradingSessionSubID​

@SesSub

 

 

 


Component

Instrument

Instrmt


Insert here the set of "Instrument" (symbology) fields defined in "Common Components of Application Messages"

 


Component

FinancingDetails

FinDetls

 

Insert here the set of "FinancingDetails" (symbology) fields defined in "Common Components of Application Messages"

 


Component

UndInstrmtGrp

Undly

 

Number of underlyings

 


​54​

​Side​

@Side

 

Required for Tradeable or Counter quotes of single instruments

 


Component

OrderQtyData

OrdQty

 

Required for Tradeable quotes or Counter quotes of single instruments

 


​63​

​SettlType​

@SettlTyp

 

 

 


​64​

​SettlDate​

@SettlDt

 

Can be used with forex quotes to specify a specific "value date".

For NDFs this is required.

 


​193​

​SettlDate2​

@SettlDt2

 

Can be used with OrdType = "Forex - Swap" to specify the "value date" for the future portion of a F/X swap.

FIX.5.0


​192​

​OrderQty2​

@Qty2

 

Can be used with OrdType = "Forex - Swap" to specify the order quantity for the future portion of a F/X swap.

FIX.5.0


​15​

​Currency​

@Ccy

 

Can be used to specify the currency of the quoted prices. May differ from the 'normal' trading currency of the instrument being quoted

 


​120​

​SettlCurrency​

@SettlCcy

 

Required for NDFs to specify the settlement currency (fixing currency).

 


Component

RateSource

RtSrc

 

 

 


Component

Stipulations

Stip

 

Insert here the set of "Stipulations" (repeating group of Fixed Income stipulations) fields defined in "Common Components of Application Messages"

 


​1​

​Account​

@Acct

 

 

 


​660​

​AcctIDSource​

@AcctIDSrc

 

 

 


​581​

​AccountType​

@AcctTyp

 

Type of account associated with the order (Origin)

 


Component

LegQuotGrp

Quot

 

Required for multileg quotes

 


​132​

​BidPx​

@BidPx

 

If F/X quote, should be the "all-in" rate (spot rate adjusted for forward points). Note that either BidPx, OfferPx or both must be specified.

 


​133​

​OfferPx​

@OfrPx

 

If F/X quote, should be the "all-in" rate (spot rate adjusted for forward points). Note that either BidPx, OfferPx or both must be specified.

 


​645​

​MktBidPx​

@MktBidPx

 

Can be used by markets that require showing the current best bid and offer

 


​646​

​MktOfferPx​

@MktOfrPx

 

Can be used by markets that require showing the current best bid and offer

 


​647​

​MinBidSize​

@MinBidSz

 

Specifies the minimum bid size. Used for markets that use a minimum and maximum bid size.

 


​134​

​BidSize​

@BidSz

 

Specifies the bid size. If MinBidSize is specified, BidSize is interpreted to contain the maximum bid size.

 


​648​

​MinOfferSize​

@MinOfrSz

 

Specifies the minimum offer size. If MinOfferSize is specified, OfferSize is interpreted to contain the maximum offer size.

 


​135​

​OfferSize​

@OfrSz

 

Specified the offer size. If MinOfferSize is specified, OfferSize is interpreted to contain the maximum offer size.

 


​110​

​MinQty​

@MinQty

 

For use in private/directed quote negotiations.

 


​62​

​ValidUntilTime​

@ValidUntilTm

 

The time when the quote will expire

 


​188​

​BidSpotRate​

@BidSpotRt

 

May be applicable for F/X quotes

 


​190​

​OfferSpotRate​

@OfrSpotRt

 

May be applicable for F/X quotes

 


​189​

​BidForwardPoints​

@BidFwdPnts

 

May be applicable for F/X quotes

 


​191​

​OfferForwardPoints​

@OfrFwdPnts

 

May be applicable for F/X quotes

 


​1065​

​BidSwapPoints​

@BidSwapPnts

 

Bid swap points of an FX Swap quote.

 


​1066​

​OfferSwapPoints​

@OfrSwapPnts

 

 

 


​631​

​MidPx​

@MidPx

 

 

 


​632​

​BidYield​

@BidYld

 

 

 


​633​

​MidYield​

@MidYld

 

 

 


​634​

​OfferYield​

@OfrYld

 

 

 


​60​

​TransactTime​

@TxnTm

 

 

 


​40​

​OrdType​

@OrdTyp

 

Can be used to specify the type of order the quote is for

 


​642​

​BidForwardPoints2​

@BidFwdPnts2

 

Bid F/X forward points of the future portion of a F/X swap quote added to spot rate. May be a negative value

FIX.5.0


​643​

​OfferForwardPoints2​

@OfrFwdPnts2

 

Offer F/X forward points of the future portion of a F/X swap quote added to spot rate. May be a negative value

FIX.5.0


​656​

​SettlCurrBidFxRate​

@SettlCurrBidFxRt

 

Can be used when the quote is provided in a currency other than the instrument's 'normal' trading currency. Applies to all bid prices contained in this quote message

 


​657​

​SettlCurrOfferFxRate​

@SettlCurrOfrFxRt

 

Can be used when the quote is provided in a currency other than the instrument's 'normal' trading currency. Applies to all offer prices contained in this quote message

 


​156​

​SettlCurrFxRateCalc​

@SettlCurrFxRtCalc

 

Can be used when the quote is provided in a currency other than the instruments trading currency.

 


​13​

​CommType​

@CommTyp

 

Can be used to show the counterparty the commission associated with the transaction.

 


​12​

​Commission​

@Comm

 

Can be used to show the counterparty the commission associated with the transaction.

 


​582​

​CustOrderCapacity​

@CustCpcty

 

For Futures Exchanges

 


​100​

​ExDestination​

@ExDest

 

Used when routing quotes to multiple markets

 


​1133​

​ExDestinationIDSource​

@ExDestIDSrc

 

 

 


​775​

​BookingType​

@BkngTyp

 

 

 



​528​

​OrderCapacity​

@Cpcty

 

 

 



​529​

​OrderRestrictions​

@Rstctions

 

 

 


​423​

​PriceType​

@PxTyp

 

 

 


Component

SpreadOrBenchmarkCurveData

SprdBnchmkCurve

 

 

 


Component

YieldData

Yield

 

 

 


​58​

​Text​

@Txt

 

 

 


​354​

​EncodedTextLen​

@EncTxtLen

 

Must be set if EncodedText field is specified and must immediately precede it.

 


​355​

​EncodedText​

@EncTxt

 

Encoded (non-ASCII characters) representation of the Text field in the encoded format specified via the MessageEncoding field.

 


Component

StandardTrailer

 


 

 



消息实现:

package cs.mina.codec.msg;

import java.util.HashSet;
import java.util.List;
import java.util.Set;

import cs.mina.exception.InValidDataException;

/*
*@author(huangxiaoping)
*@date 2013-11-30
*/
public class QuoteMsg extends BaseMsg {
private Tag parties = new PartiesTag(false);
private Tag instrument = new InstrumentTag(true);
private Tag bidID = new Tag("390", "String", false);
private Tag offerID = new Tag("1867", "String", false);
private Tag quoteType = new Tag("537", "int", false);
private Tag side = new Tag("54", "char", false);
private Tag bidSize = new Tag("134", "Qty", false);
private Tag offerSize = new Tag("135", "Qty", false);
private Tag bidPx = new Tag("132", "Price", false);
private Tag offerPx = new Tag("133", "Price", false);
private Tag transactTime = new Tag("60", "UTCTimestamp", true);
private Tag positionEffect = new Tag("77", "char", false);
private Tag orderRestrictions = new Tag("529", "MultipleCharValue", false);
private Tag text = new Tag("58", "String", false);
private Tag valueChecksGrp = new ValueChecksGrpTag(false);

private Set<String> tagIdsSet = new HashSet<String>();

public QuoteMsg() {
this.getHeadEntity().getMsgType().setTagValue("S");
tagIdsSet.add("390");
tagIdsSet.add("1867");
tagIdsSet.add("537");
tagIdsSet.add("54");
tagIdsSet.add("134");
tagIdsSet.add("135");
tagIdsSet.add("132");
tagIdsSet.add("133");
tagIdsSet.add("60");
tagIdsSet.add("77");
tagIdsSet.add("529");
tagIdsSet.add("58");
this.bodyEntity.getBodyTagList().add(parties);
this.bodyEntity.getBodyTagList().add(instrument);
this.bodyEntity.getBodyTagList().add(bidID);
this.bodyEntity.getBodyTagList().add(offerID);
this.bodyEntity.getBodyTagList().add(quoteType);
this.bodyEntity.getBodyTagList().add(side);
this.bodyEntity.getBodyTagList().add(bidSize);
this.bodyEntity.getBodyTagList().add(offerSize);
this.bodyEntity.getBodyTagList().add(bidPx);
this.bodyEntity.getBodyTagList().add(offerPx);
this.bodyEntity.getBodyTagList().add(transactTime);
this.bodyEntity.getBodyTagList().add(positionEffect);
this.bodyEntity.getBodyTagList().add(orderRestrictions);
this.bodyEntity.getBodyTagList().add(text);
this.bodyEntity.getBodyTagList().add(valueChecksGrp);
}

@Override
public void decodeBody() {

}

@Override
public void validate() {
this.headEntity.validate();
List<Tag> bodyTagList = this.bodyEntity.getBodyTagList();
for (int i = 0; i < bodyTagList.size(); i++) {
bodyTagList.get(i).validate();
}
this.tailerEntity.validate();
if (quoteType.getTagValue() != null) {
if (!(Integer.parseInt(quoteType.getTagValue()) >= 0 && Integer
.parseInt(quoteType.getTagValue()) <= 3)) {
throw new InValidDataException("quoteType错误["
+ quoteType.getTagId() + "=" + quoteType.getTagValue()
+ "]");
}
}
if (side.getTagValue() != null) {
if (!MsgUtil.side.contains(side.getTagValue())) {
throw new InValidDataException("side错误[" + side.getTagId()
+ "=" + side.getTagValue() + "]");
}
}
if (positionEffect.getTagValue() != null) {
if (!MsgUtil.positionEffect.contains(positionEffect.getTagValue())) {
throw new InValidDataException("positionEffect错误["
+ positionEffect.getTagId() + "="
+ positionEffect.getTagValue() + "]");
}
}
}

public Tag getParties() {
return parties;
}

public void setParties(Tag parties) {
this.parties = parties;
}

public Tag getInstrument() {
return instrument;
}

public void setInstrument(Tag instrument) {
this.instrument = instrument;
}

public Tag getBidID() {
return bidID;
}

public void setBidID(Tag bidID) {
this.bidID = bidID;
}

public Tag getOfferID() {
return offerID;
}

public void setOfferID(Tag offerID) {
this.offerID = offerID;
}

public Tag getQuoteType() {
return quoteType;
}

public void setQuoteType(Tag quoteType) {
this.quoteType = quoteType;
}

public Tag getSide() {
return side;
}

public void setSide(Tag side) {
this.side = side;
}

public Tag getBidSize() {
return bidSize;
}

public void setBidSize(Tag bidSize) {
this.bidSize = bidSize;
}

public Tag getOfferSize() {
return offerSize;
}

public void setOfferSize(Tag offerSize) {
this.offerSize = offerSize;
}

public Tag getBidPx() {
return bidPx;
}

public void setBidPx(Tag bidPx) {
this.bidPx = bidPx;
}

public Tag getOfferPx() {
return offerPx;
}

public void setOfferPx(Tag offerPx) {
this.offerPx = offerPx;
}

public Tag getTransactTime() {
return transactTime;
}

public void setTransactTime(Tag transactTime) {
this.transactTime = transactTime;
}

public Tag getPositionEffect() {
return positionEffect;
}

public void setPositionEffect(Tag positionEffect) {
this.positionEffect = positionEffect;
}

public Tag getOrderRestrictions() {
return orderRestrictions;
}

public void setOrderRestrictions(Tag orderRestrictions) {
this.orderRestrictions = orderRestrictions;
}

public Tag getText() {
return text;
}

public void setText(Tag text) {
this.text = text;
}

public Tag getValueChecksGrp() {
return valueChecksGrp;
}

public void setValueChecksGrp(Tag valueChecksGrp) {
this.valueChecksGrp = valueChecksGrp;
}

public Set<String> getTagIdsSet() {
return tagIdsSet;
}

public void setTagIdsSet(Set<String> tagIdsSet) {
this.tagIdsSet = tagIdsSet;
}

}


消息处理:略




标签:16,quote,fix,private,add,Tag,void,new,public
From: https://blog.51cto.com/u_11979904/5982991

相关文章

  • fix协议介绍18-取消查询订单(QuoteCancel)
    FIX.5.0SP2MessageQuoteCancel [type'Z']<QuotCxl>TheQuoteCancelmessageisusedbyanoriginatorofquotestocancelquotes.TheQuoteCancelmessages......
  • 字符编码:Unicode & UTF-16 & UTF-8
    ASCII码使用一个字节(8位),对128个字符进行编码;最高位始终为0;码数范围为0000_0000(0x00)到0111_1111(0x7F);Unicode开始的编码设计使用两个字节(16位),对65536个字符进行编......
  • 【CF1672I】PermutationForces(线段树)
    记\(c_i=|i-p_i|\)。可以证明,删掉一个\(c_i\leqs\)的点后,只会让\(c_j>s\)的点的\(c_j\)变小,且原本\(c_j\leqs\)的点的\(c_j\)仍不会大过\(s\)。也就是说我们......
  • CF1416D Graph and Queries
    CF1416DGraphandQueries看到这题第一眼就想到时光倒流,但是操作一只能顺序做,这就很困惑了。但是一个比较好的性质是操作一只会改变点值,操作二只会改变图的形态,启发我们......
  • 暴风影音16 v9.05.1202.1111 绿色版
    修改历史:2022.12.14:自改官方 9.05.1202.1111最新正式版本2022.06.27:自改官方9.04.1029.1111最新正式版本......修改内容:by.呆彤儿/WeiDaXia基于官方版精简,解除多......
  • 暴风影音16 v9.05.1202.1111 绿色版
    修改历史:2022.12.14:自改官方 9.05.1202.1111最新正式版本2022.06.27:自改官方9.04.1029.1111最新正式版本......修改内容:by.呆彤儿/WeiDaXia基于官方版精简,解除多......
  • lctf2016_pwn200 堆利用
    lctf2016:pwn200堆利用一、信息收集RELRO:在Linux系统安全领域数据可以写的存储区就会是攻击的目标,尤其是存储函数指针的区域。所以在安全防护的角度来说尽量减少可写......
  • ASIS_CTF_2016_b00ks
    ASIS_CTF_2016_b00ks一、信息收集RELRO:在Linux系统安全领域数据可以写的存储区就会是攻击的目标,尤其是存储函数指针的区域。所以在安全防护的角度来说尽量减少可写的......
  • Selenium58-优化fixture
    v4_1问题代码运行效率较低:prepare_and_exit包含所有前置和后置步骤,每组测试数据都从重新启动浏览器开始到关闭浏览器结束。。思考:是否可以省略每组数据测试时的重......
  • Selenium57-使用fixture
    第四版使用fixturetest_后台_双创_基础设置_赛区管理_添加赛区_case_v4_1.py使用fixture来做前置和后置处理。使用yield来分隔前置后后置处理步骤。定义prepare_......