Package org.fao.geonet.kernel

Examples of org.fao.geonet.kernel.DataManager.deleteMetadata()


    try {
      if (dm.existsMetadataUuid(uuid) && !uuidAction.equals(Params.NOTHING)) {
                // user has privileges to replace the existing metadata
                if(dm.getAccessManager().canEdit(context, dm.getMetadataId(uuid))) {
                    dm.deleteMetadata(context, dm.getMetadataId(uuid));
                    if(Log.isDebugEnabled(Geonet.MEF))
                        Log.debug(Geonet.MEF, "Deleting existing metadata with UUID : " + uuid);
                }
                // user does not hav privileges to replace the existing metadata
                else {
View Full Code Here


          //--- remove the metadata directory
          File pb = new File(Lib.resource.getMetadataDir(context, id));
          FileCopyMgr.removeDirectoryOrFile(pb);
 
          //--- delete metadata and return status
          dataMan.deleteMetadata(context, id);
                    if(context.isDebugEnabled())
                        context.debug("  Metadata with id " + id + " deleted.");
          metadata.add(Integer.valueOf(id));
        }
      } else
View Full Code Here

    FileCopyMgr.removeDirectoryOrFile(pb);
   
    //-----------------------------------------------------------------------
    //--- delete metadata and return status

    dataMan.deleteMetadata(context, id);

    Element elResp = new Element(Jeeves.Elem.RESPONSE);
    elResp.addContent(new Element(Geonet.Elem.ID).setText(id));

    return elResp;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.