Skip to content

In the encodeWith method of the dto object, the Java code generator did not handle all the keyword replacements properly. #1081

@shenzlx

Description

@shenzlx

schema.xml

  <sbe:message id="100" name="OnRtnBulletin" >
        <field id="1" name="ExchangeID" type="TThostFtdcExchangeIDType" />
        <field id="2" name="TradingDay" type="TThostFtdcDateType"  />
        <field id="3" name="BulletinID" type="TThostFtdcBulletinIDType" />
        <field id="4" name="SequenceNo" type="TThostFtdcSequenceNoType" />
        <field id="5" name="NewsType" type="TThostFtdcNewsTypeType"  />
        <field id="6" name="NewsUrgency" type="TThostFtdcNewsUrgencyType" />
        <field id="7" name="SendTime" type="TThostFtdcTimeType"  />
        <field id="8" name="Abstract" type="TThostFtdcAbstractType" />
        <field id="9" name="ComeFrom" type="TThostFtdcComeFromType" />
        <field id="10" name="Content" type="TThostFtdcContentType"  />
        <field id="11" name="URLLink" type="TThostFtdcURLLinkType"  />
        <field id="12" name="MarketID" type="TThostFtdcMarketIDType" />
    </sbe:message>

generated code section:

    public static void encodeWith(OnRtnBulletinEncoder encoder, OnRtnBulletinDto dto)
    {
        encoder.exchangeID(dto.exchangeID());
        encoder.tradingDay(dto.tradingDay());
        encoder.bulletinID(dto.bulletinID());
        encoder.sequenceNo(dto.sequenceNo());
        encoder.newsType(dto.newsType());
        encoder.newsUrgency(dto.newsUrgency());
        encoder.sendTime(dto.sendTime());
        encoder.**abstract**(dto.abstractSBE());
        encoder.comeFrom(dto.comeFrom());
        encoder.content(dto.content());
        encoder.uRLLink(dto.uRLLink());
        encoder.marketID(dto.marketID());
    }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions