Skip to content

Instantly share code, notes, and snippets.

@viettranit
Created March 30, 2018 15:13
Show Gist options
  • Save viettranit/0d469a01af11290ff705123428e66725 to your computer and use it in GitHub Desktop.
Save viettranit/0d469a01af11290ff705123428e66725 to your computer and use it in GitHub Desktop.
package cust.iface.app.item;
import java.rmi.RemoteException;
import java.util.Map;
import psdi.iface.mic.MicSetOut;
import psdi.iface.mos.MosDetailInfo;
import psdi.mbo.MboRemote;
import psdi.util.MXException;
import org.apache.axiom.om.util.Base64;
public class MoutItemProcess extends MicSetOut {
public MoutItemProcess() throws MXException, RemoteException {
}
public int checkBusinessRules(MboRemote mbo, MosDetailInfo mosDetInfo, Map<String, Object> ovrdColValueMap) throws MXException, RemoteException {
if (mbo.getName().equals("IMAGELIB")) {
byte[] imageBytes = mbo.getBytes("IMAGE");
String strImage = Base64.encode(imageBytes);
ovrdColValueMap.put("IMAGE", strImage);
}
return 1;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment