
com.day.cq.wcm.webservicesupport.Service Maven / Gradle / Ivy
/*************************************************************************
*
* ADOBE CONFIDENTIAL
* __________________
*
* Copyright 2011 Adobe Systems Incorporated
* All Rights Reserved.
*
* NOTICE: All information contained herein is, and remains
* the property of Adobe Systems Incorporated and its suppliers,
* if any. The intellectual and technical concepts contained
* herein are proprietary to Adobe Systems Incorporated and its
* suppliers and are protected by trade secret or copyright law.
* Dissemination of this information or reproduction of this material
* is strictly forbidden unless prior written permission is obtained
* from Adobe Systems Incorporated.
**************************************************************************/
package com.day.cq.wcm.webservicesupport;
import org.apache.sling.api.resource.Resource;
import org.apache.sling.api.resource.ValueMap;
import aQute.bnd.annotation.ProviderType;
import com.day.cq.wcm.api.Template;
/**
* Represents a web service entry in context of web service configurations. A
* {@link Service} acts mainly as container for {@link Configuration} entries.
*
* @since 5.5
*/
@ProviderType
public interface Service {
/**
* Base path for service {@link Resource}s.
*/
static final String BASE_PATH = "/etc/cloudservices";
/**
* Return the jcr:title property of the service.
*
* @return String representation of title
*/
String getTitle();
/**
* Returns an Long value of the includsionRank property.
*
* @return Long value of rank
*/
Long getInclusionRank();
/**
* Return jcr:description property of the service.
*
* @return String representation description
*/
String getDescription();
/**
* Returns the name of the service. This is the first segment of the
* configuration path after the base path.
*
* @return String representation of name
*/
String getName();
/**
* Returns the path of the service.
*
* @return String of service path or null
*/
String getPath();
/**
* Returns a path to a related page component or null
if not
* defined.
*
* @return String of a path or null
*/
String getComponentReference();
/**
* Returns the URL to the service or null
if not defined.
*
* @return String of an URL or null
*/
String getServiceUrl();
/**
* Returns the URL label for the service URL link or null
if not defined.
* @return String of a URL label or null
*/
String getServiceUrlLabel();
/**
* Returns the path to an icon for this service or null
if
* this service does not provide an icon.
*
* @return String of a path to an icon or null
*/
String getIconPath();
/**
* Returns the path to a thumbnail for this service or null
if
* this service does not provide a thumbnail.
*
* @return String of a path to an icon or null
*/
String getThumbnailPath();
/**
* Returns the pages {@link Template} or null
if no template has
* been found or the current user does not have read access to the
* template resource specified by the path in the page's template property.
* This is the case on publish instances using default ACL configuration
* (anonymous cannot read templates).
*
* @return Page {@link Template} or null
*/
Template getTemplate();
/**
* Returns the service {@link Resource}.
*
* @return {@link Resource} or null
*/
Resource getResource();
/**
* Returns the {@link Resource} of the services content or null
* if the service has no content.
*
* @return Content {@link Resource} or null
*/
Resource getContentResource();
/**
* Returns a value map of the service content. If the service has no content
* an empty map is returned.
*
* @return A {@link ValueMap} or {@link ValueMap#EMPTY}
*/
ValueMap getProperties();
/**
* Returns an array of paths to selectable child templates.
*
* @return A String array of selectable template paths
*/
String[] getSelectableChildren();
/**
* Checks if provided template path is selectable.
*
* @param templatePath templatePath
* @return true
if templatePath
is selectable,
* false
otherwise
*/
Boolean isSelectableChild(String templatePath);
/**
* Indicates if the service has the property 'visible' set to true. If the
* property is missing this method will return true
.
*
* @return false
if the property is set to false,
* true
otherwise or if the property is missing
*/
Boolean isVisible();
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy