Package com.dotmarketing.business.ajax

Source Code of com.dotmarketing.business.ajax.InodeAjax

package com.dotmarketing.business.ajax;

import com.dotmarketing.beans.Identifier;
import com.dotmarketing.business.APILocator;
import com.dotmarketing.business.IdentifierAPI;
import com.dotmarketing.common.db.DotConnect;
import com.dotmarketing.util.InodeUtils;
import com.dotmarketing.util.Logger;

public class InodeAjax {
 
  public int compareInodes(String inodeStr1,String inodeStr2){
    return InodeUtils.compareInodes(inodeStr1, inodeStr2);
  }
 
  public String getInodeUrl(String inode){


   
    try {

      DotConnect dc = new DotConnect();
      dc.setSQL("select * from inode where inode = ?");
      dc.addParam(inode);
      Identifier id = null;
      IdentifierAPI iapi = APILocator.getIdentifierAPI();
      id=   iapi.findFromInode(dc.getString("identifier"));
      return id.getURI();
    } catch (Exception e) {
      Logger.warn(this, "Unable to find identifier : " + inode);

    }
   
   
    return "";
   
   
   
  }
 
 

}
TOP

Related Classes of com.dotmarketing.business.ajax.InodeAjax

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.