Package com.dotmarketing.portlets.contentlet.business

Examples of com.dotmarketing.portlets.contentlet.business.HostAPI.findParentHost()


  public Permissionable getParentPermissionable() throws DotDataException {

    try {
      User systemUser = APILocator.getUserAPI().getSystemUser();
      HostAPI hostAPI = APILocator.getHostAPI();
      Host host = hostAPI.findParentHost(this, systemUser, false);

      if (host == null) {
        host = hostAPI.findSystemHost(systemUser, false);
      }
      return host;
View Full Code Here


    Folder folder = APILocator.getFolderAPI().findParentFolder(object, APILocator.getUserAPI().getSystemUser(),false);
    Host host;
    try {
      User systemUser = APILocator.getUserAPI().getSystemUser();
      host = hostAPI.findParentHost(folder, systemUser, false);
    } catch (DotDataException e) {
      Logger.error(HTMLPageFactory.class, e.getMessage(), e);
      throw new DotRuntimeException(e.getMessage(), e);
    } catch (DotSecurityException e) {
      Logger.error(HTMLPageFactory.class, e.getMessage(), e);
View Full Code Here

      identifier.setId(null);
    }

    Host host;
    try {
      host = hostAPI.findParentHost(folder, systemUser, false);
    } catch (DotSecurityException e) {
      throw new DotStateException("I can't find the parent host!");
    }
   
    if("folder".equals(identifier.getAssetType()) && APILocator.getHostAPI().findSystemHost().getIdentifier().equals(host.getIdentifier())){
View Full Code Here

  public Permissionable getParentPermissionable() throws DotDataException {

    try {
      User systemUser = APILocator.getUserAPI().getSystemUser();
      HostAPI hostAPI = APILocator.getHostAPI();
      Host host = hostAPI.findParentHost(this, systemUser, false);

      if (host == null) {
        host = hostAPI.findSystemHost(systemUser, false);
      }
      return host;
View Full Code Here


    //Copy the host
    Host h;
    try {
      h = hostAPI.findParentHost(currentContainer, APILocator.getUserAPI().getSystemUser(), false);
    } catch (DotSecurityException e) {
      Logger.error(ContainerFactory.class, e.getMessage(), e);
      throw new DotRuntimeException(e.getMessage(), e);
    }
        //TreeFactory.saveTree(new Tree(h.getIdentifier(), newContainer.getInode()));
View Full Code Here

    folderMap.put("type", "folder");
    folderMap.put("name", f.getName());
    folderMap.put("id", f.getInode());
    folderMap.put("inode", f.getInode());
    folderMap.put("defaultFileType", f.getDefaultFileType());
    String currentPath = hostAPI.findParentHost(f, userWebAPI.getSystemUser(), false).getHostname();
    String fullPath = currentPath + ":/" + f.getName();
    String absolutePath = "/" + f.getName();
    folderMap.put("fullPath", fullPath);
    folderMap.put("absolutePath", absolutePath);
        return folderMap;
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.