FIX.5.0SP2 Message
OrderMassCancelRequest [type 'q']
<OrdMassCxlReq>
The order mass cancel request message requests the cancellation of all of the remaining quantity of a group of orders matching criteria specified within the request. NOTE: This message can only be used to cancel order messages (reduce the full quantity).
Added FIX.4.3
Expand Components | Collapse Components
Field or Component | Field Name | FIXML name | Req'd | Comments | Depr. |
---|
![]() | Component | StandardHeader | BaseHeader | ![]() | MsgType = q (lowercase Q) |
![]() | 11 | ClOrdID | @ClOrdID | ![]() | Unique ID of Order Mass Cancel Request as assigned by the institution. | |
![]() | 526 | SecondaryClOrdID | @ClOrdID2 | |||
![]() | 530 | MassCancelRequestType | @ReqTyp | ![]() | Specifies the type of cancellation requested | |
![]() | 336 | TradingSessionID | @SesID | Trading Session in which orders are to be canceled | ||
![]() | 625 | TradingSessionSubID | @SesSub |
![]() | Component | Parties | Pty | Insert here the set of "Parties" (firm identification) fields defined in "common components of application messages" |
![]() | Component | TargetParties | TgtPty | Can be used to specify the parties to whom the Order Mass Cancel should apply. |
![]() | Component | Instrument | Instrmt | Insert here the set of "Instrument" (symbology) fields defined in "Common Components of Application Messages" |
![]() | Component | UnderlyingInstrument | Undly | Insert here the set of "UnderlyingInstrument" (underlying symbology) fields defined in "Common Components of Application Messages" |
![]() | 1301 | MarketID | @MktID | Required for MassCancelRequestType = 8 (Cancel orders for a market) | ||
![]() | 1300 | MarketSegmentID | @MktSegID | Required for MassCancelRequestType = 9 (Cancel orders for a market segment) | ||
![]() | 54 | Side | @Side | Optional qualifier used to indicate the side of the market for which orders are to be canceled. Absence of this field indicates that orders are to be canceled regardless of side. | ||
![]() | 60 | TransactTime | @TxnTm | ![]() | Time this order request was initiated/released by the trader or trading system. | |
![]() | 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-29
*/
public class OrderMassCancelRequestMsg extends BaseMsg {
private Tag clOrdID=new Tag("11","String",true);
private Tag parties=new PartiesTag(false);
private Tag instrument=new InstrumentTag(true);
private Tag transactTime=new Tag("60","UTCTimestamp",true);
private Tag side=new Tag("54","char",false);
private Tag massCancelRequestType=new Tag("530","char",true);
private Tag marketSegmentID=new Tag("1300","String",false);
private Set<String> tagIdsSet=new HashSet<String>();
public OrderMassCancelRequestMsg(){
this.getHeadEntity().getMsgType().setTagValue("q");
tagIdsSet.add("11");
tagIdsSet.add("60");
tagIdsSet.add("54");
tagIdsSet.add("530");
tagIdsSet.add("1300");
this.bodyEntity.getBodyTagList().add(clOrdID);
this.bodyEntity.getBodyTagList().add(parties);
this.bodyEntity.getBodyTagList().add(instrument);
this.bodyEntity.getBodyTagList().add(transactTime);
this.bodyEntity.getBodyTagList().add(side);
this.bodyEntity.getBodyTagList().add(massCancelRequestType);
this.bodyEntity.getBodyTagList().add(marketSegmentID);
}
@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(massCancelRequestType.getTagValue()!=null){
if(!MsgUtil.massCancelRequestType.contains(massCancelRequestType.getTagValue())){
throw new InValidDataException("massCancelRequestType错误["+massCancelRequestType.getTagId()+"="+massCancelRequestType.getTagValue()+"]");
}
}
}
public Tag getClOrdID() {
return clOrdID;
}
public void setClOrdID(Tag clOrdID) {
this.clOrdID = clOrdID;
}
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 getTransactTime() {
return transactTime;
}
public void setTransactTime(Tag transactTime) {
this.transactTime = transactTime;
}
public Tag getSide() {
return side;
}
public void setSide(Tag side) {
this.side = side;
}
public Tag getMassCancelRequestType() {
return massCancelRequestType;
}
public void setMassCancelRequestType(Tag massCancelRequestType) {
this.massCancelRequestType = massCancelRequestType;
}
public Tag getMarketSegmentID() {
return marketSegmentID;
}
public void setMarketSegmentID(Tag marketSegmentID) {
this.marketSegmentID = marketSegmentID;
}
public Set<String> getTagIdsSet() {
return tagIdsSet;
}
public void setTagIdsSet(Set<String> tagIdsSet) {
this.tagIdsSet = tagIdsSet;
}
}
业务处理:略