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

problem with byte[ ] as a custom Operation input/output

  • 1.  problem with byte[ ] as a custom Operation input/output

    Posted Wed April 10, 2002 07:43 AM

    dear,

    I am implementing a custom operation that returns a byte in output.
    The way this is done is the following, I declare a hidden “outfieldType”
    in the Options Tab and I set it in the “outField” namespace (see below).

      adapterdescriptor.createGroup("parameters", new String[] {
    "inField","outField",
    "outFieldType"});
    
    adapterdescriptor.setHidden("outFieldType");
    
    adapterdescriptor.setNamespace("inField", "inputExpressions", null);
    adapterdescriptor.setNamespace("outField", adapterdescriptor.OUTPUT_FIELD_NAMES,
    new String[] {"outFieldType"});
    
    
    public String getOutFieldType() {
    return "byte[]";
    }
    
    private String inField;
    private String outField;
    

    I made a successful integration with this operation but the problem is at run-time
    when executing the following line:
    OUTbrokerevent.setByteSeqField(this.getOutField(),0,outputBytes.length,outputBytes.length,outputBytes);

    I get an error
    “Field Type Mismatch (204-1119): Field ‘SOGA17a’ is not a sequence of type byte.”

    (where SOGA17a is the string that I filled in the “outField” Field in the Options Tab.)

    • Am I missing anything in the code ?

    thanks very much,

    Cedric


    #webMethods
    #Integration-Server-and-ESB
    #Adapters-and-E-Standards