|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.opencms.ade.publish.CmsPublish
public class CmsPublish
ADE publishing features.
Field Summary | |
---|---|
protected static int |
GROUP_DAYS_NUMBER
The number of day groups. |
protected static int |
GROUP_SESSIONS_GAP
The gap between session groups. |
protected static int |
GROUP_SESSIONS_NUMBER
The number of session groups. |
Constructor Summary | |
---|---|
CmsPublish(CmsObject cms)
Constructor with default options. |
|
CmsPublish(CmsObject cms,
CmsPublishOptions options)
Constructor with options. |
Method Summary | |
---|---|
protected Set<CmsResource> |
getAlreadyPublishedResources()
Returns already published resources. |
protected org.opencms.ade.publish.CmsPublish.ResourcesAndRelated |
getBlockingLockedResources(Set<CmsResource> exclude)
Returns locked resources that do not belong to the current user. |
List<CmsPublishResource> |
getBrokenResources(List<CmsResource> pubResources)
Checks for possible broken links when the given list of resources would be published. |
List<CmsProjectBean> |
getManageableProjects()
Returns the current user's manageable projects. |
CmsPublishOptions |
getOptions()
Returns the options. |
protected String |
getOuAwareName(String name)
Returns the simple name if the ou is the same as the current user's ou. |
List<CmsPublishGroup> |
getPublishGroups()
Returns the list of publish groups with resources that can be published. |
protected org.opencms.ade.publish.CmsPublish.ResourcesAndRelated |
getPublishResources()
Returns the resources stored in the user's publish list. |
protected List<CmsPublishResource> |
getRelatedResources(CmsResource resource,
Set<CmsResource> resources,
Set<CmsResource> published,
org.opencms.ade.publish.CmsPublish.ResourcesAndRelated permissions,
org.opencms.ade.publish.CmsPublish.ResourcesAndRelated locked)
Returns a string with a list of related resources in the publish list. |
protected CmsPublishResourceInfo |
getResourceInfo(CmsResource resource,
Set<CmsResource> published,
org.opencms.ade.publish.CmsPublish.ResourcesAndRelated permissions,
org.opencms.ade.publish.CmsPublish.ResourcesAndRelated locked)
Returns the additional info for the given resource. |
protected String |
getResourceName(String rootPath,
String siteRoot)
Formats the given resource path depending on the site root. |
protected org.opencms.ade.publish.CmsPublish.ResourcesAndRelated |
getResourcesWithoutPermissions(Set<CmsResource> exclude)
Returns the sublist of the publish list with resources without publish permissions. |
void |
publishResources(List<CmsResource> resources)
Publishes the given list of resources. |
CmsPublishResource |
relationToBean(CmsRelation relation)
Creates a publish resource bean from the target information of a relation object. |
void |
removeResourcesFromPublishList(Collection<CmsUUID> idsToRemove)
Removes the given resources from the user's publish list. |
protected CmsPublishResource |
resourceToBean(CmsResource resource,
CmsPublishResourceInfo info,
boolean removable,
List<CmsPublishResource> related)
Creates a publish resource bean instance from the given parameters. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static final int GROUP_DAYS_NUMBER
protected static final int GROUP_SESSIONS_GAP
protected static final int GROUP_SESSIONS_NUMBER
Constructor Detail |
---|
public CmsPublish(CmsObject cms)
cms
- the current cms contextpublic CmsPublish(CmsObject cms, CmsPublishOptions options)
cms
- the current cms contextoptions
- the options to useMethod Detail |
---|
public List<CmsPublishResource> getBrokenResources(List<CmsResource> pubResources)
pubResources
- list of resources to be published
public List<CmsProjectBean> getManageableProjects()
public CmsPublishOptions getOptions()
public List<CmsPublishGroup> getPublishGroups()
public void publishResources(List<CmsResource> resources) throws CmsException
resources
- list of resources to publish
CmsException
- if something goes wrongpublic CmsPublishResource relationToBean(CmsRelation relation)
relation
- the relation to use
public void removeResourcesFromPublishList(Collection<CmsUUID> idsToRemove) throws CmsException
idsToRemove
- list of structure ids identifying the resources to be removed
CmsException
- if something goes wrongprotected Set<CmsResource> getAlreadyPublishedResources()
protected org.opencms.ade.publish.CmsPublish.ResourcesAndRelated getBlockingLockedResources(Set<CmsResource> exclude)
exclude
- the resources to exclude
CmsLock.getBlockingLockedResources()
protected String getOuAwareName(String name)
name
- the fully qualified name to check
protected org.opencms.ade.publish.CmsPublish.ResourcesAndRelated getPublishResources()
protected List<CmsPublishResource> getRelatedResources(CmsResource resource, Set<CmsResource> resources, Set<CmsResource> published, org.opencms.ade.publish.CmsPublish.ResourcesAndRelated permissions, org.opencms.ade.publish.CmsPublish.ResourcesAndRelated locked)
resource
- the resource to useresources
- the resources the user can really publishpublished
- the already published resourcespermissions
- the resource the current user does not have publish permissions forlocked
- the locked resources
null
if noneprotected CmsPublishResourceInfo getResourceInfo(CmsResource resource, Set<CmsResource> published, org.opencms.ade.publish.CmsPublish.ResourcesAndRelated permissions, org.opencms.ade.publish.CmsPublish.ResourcesAndRelated locked)
resource
- the resource to usepublished
- the already published resourcespermissions
- the resource the current user does not have publish permissions forlocked
- the locked resources
protected String getResourceName(String rootPath, String siteRoot)
rootPath
- the resource path to formatsiteRoot
- the site root
protected org.opencms.ade.publish.CmsPublish.ResourcesAndRelated getResourcesWithoutPermissions(Set<CmsResource> exclude)
exclude
- the resources to exclude
protected CmsPublishResource resourceToBean(CmsResource resource, CmsPublishResourceInfo info, boolean removable, List<CmsPublishResource> related)
resource
- the resourceinfo
- the publish information, if anyremovable
- if removablerelated
- the list of related resources
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |