IBM webMethods Hybrid Integration

IBM webMethods Hybrid Integration

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
  • 1.  Deprecation of getTable()

    Posted Fri May 31, 2013 10:55 AM

    Bringing an application up from Applinx 5.2.5 to 8.2.2, I get a deprecation warning. (bunches, actually)
    Here is a code snippet:

    package contexts;
    import com.sabratec.applinx.baseobject.table.*;
    import com.sabratec.applinx.common.generate.GXTableSerializer;
    public class Chn_excel extends GXBasicContext
    {
    public void gx_onLoad() {
    super.gx_onLoad() ;
    try{
    gx_attach();
    GXITable gx_table = null;
    /// Retrieving A table stored in the http session
    Object obj = getSession().getAttribute(EXCEL_TABLE_SESSION_KEY);
    if (obj != null){
    gx_table = (GXITable)obj;
    }
    else{
    gx_table = getGXSession().getTable();
    }

    How can I fix this easily? Any help will be appreciated.


    #webMethods
    #ApplinX
    #Mainframe-Integration


  • 2.  RE: Deprecation of getTable()

    Posted Sun June 02, 2013 06:55 AM

    It is replaced by:

    getSession().getScreen().getTables()[0]

    #webMethods
    #ApplinX
    #Mainframe-Integration


  • 3.  RE: Deprecation of getTable()

    Posted Mon June 03, 2013 11:24 AM

    Can you tell me how it would fit into the attached?

    Chn_excel.java (5.62 KB)


    #webMethods
    #ApplinX
    #Mainframe-Integration


  • 4.  RE: Deprecation of getTable()

    Posted Mon June 03, 2013 12:44 PM

    It’s a little hard to look at the code without the context but basically it should be this, in the else caluse:
    gx_table = getGXSession().getScreen().getTables()[0];


    #webMethods
    #Mainframe-Integration
    #ApplinX


  • 5.  RE: Deprecation of getTable()

    Posted Mon June 03, 2013 01:00 PM

    Great! Thanks so much for your help, it works fine. Removes several hundred deprecation warnings for me.


    #webMethods
    #Mainframe-Integration
    #ApplinX