Tuesday, February 28, 2012

ADF:Deleting MDS document


        MDSInstance mdsi =  (MDSInstance)ADFContext.getCurrent().getMDSInstanceAsObject();
        MDSSession mdss = (MDSSession)ADFContext.getCurrent().getMDSSessionAsObject();
        MetadataObject mo;
        try {
            mo = mdss.getMetadataObject("/sessiondef/oracle/apps/atk/ess/MyJobDefintion6AtkEssParamaterViewDef.xml");
            MOReference mr = mo.getReference();
            mdss.deleteMetadataObject(mr);
        } catch (Exception e) {
            e.printStackTrace();
        }