org.rhq.plugins.cron
Class CronComponent

java.lang.Object
  extended by org.rhq.plugins.augeas.AugeasConfigurationComponent<PlatformComponent>
      extended by org.rhq.plugins.cron.CronComponent
All Implemented Interfaces:
AvailabilityFacet, ConfigurationFacet, CreateChildResourceFacet, DeleteResourceFacet, ResourceComponent<PlatformComponent>

public class CronComponent
extends AugeasConfigurationComponent<PlatformComponent>
implements CreateChildResourceFacet

Provides an summary of all entries in the crontabs split into hourly/daily/weekly/monthly entries. Is able to create new cron tabs.

Author:
Lukas Krejci

Field Summary
 
Fields inherited from class org.rhq.plugins.augeas.AugeasConfigurationComponent
AUGEAS_MODULE_NAME_PROP, AUGEAS_ROOT_PATH_PROP, DEFAULT_AUGEAS_ROOT_PATH, EXCLUDE_GLOBS_PROP, INCLUDE_GLOBS_PROP, RESOURCE_CONFIGURATION_ROOT_NODE_PROP
 
Constructor Summary
CronComponent()
           
 
Method Summary
 CreateResourceReport createResource(CreateResourceReport report)
           
protected  String getAugeasPathRelativeToParent(org.rhq.core.domain.configuration.definition.PropertyDefinition propDef, AugeasNode parentNode, net.augeas.Augeas augeas)
           
protected  String getResourceConfigurationRootPath()
           
protected  Object toPropertyValue(org.rhq.core.domain.configuration.definition.PropertyDefinitionSimple propDefSimple, net.augeas.Augeas augeas, AugeasNode node)
           
protected  void updateCrontab(String crontabPath, org.rhq.core.domain.configuration.definition.ConfigurationDefinition crontabConfigurationDefinition, org.rhq.core.domain.configuration.Configuration crontabConfiguration)
           
 void updateResourceConfiguration(ConfigurationUpdateReport report)
           
 
Methods inherited from class org.rhq.plugins.augeas.AugeasConfigurationComponent
close, createAugeas, createPropertyList, createPropertyMap, createPropertySimple, deleteResource, finalize, getAugeas, getAugeasLoadPath, getAugeasRootPath, getAvailability, getChildResourceConfigurationRootLabel, getChildResourceConfigurationRootPath, getConfigurationFiles, getExistingChildNodeForListMemberPropertyMap, getNewListMemberNode, getNodeInsertionPoint, getResourceContext, getResourceDescription, initAugeas, isAugeasAvailable, loadProperty, loadResourceConfiguration, populatePropertyMap, setNode, setNodeFromPropertyList, setNodeFromPropertyMap, setNodeFromPropertySimple, setupAugeasModules, start, stop, summarizeAugeasError, toNodeValue, updateStructuredConfiguration, validateResourceConfiguration
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CronComponent

public CronComponent()
Method Detail

getResourceConfigurationRootPath

protected String getResourceConfigurationRootPath()
Overrides:
getResourceConfigurationRootPath in class AugeasConfigurationComponent<PlatformComponent>

createResource

public CreateResourceReport createResource(CreateResourceReport report)
Specified by:
createResource in interface CreateChildResourceFacet
Overrides:
createResource in class AugeasConfigurationComponent<PlatformComponent>

updateResourceConfiguration

public void updateResourceConfiguration(ConfigurationUpdateReport report)
Specified by:
updateResourceConfiguration in interface ConfigurationFacet
Overrides:
updateResourceConfiguration in class AugeasConfigurationComponent<PlatformComponent>

getAugeasPathRelativeToParent

protected String getAugeasPathRelativeToParent(org.rhq.core.domain.configuration.definition.PropertyDefinition propDef,
                                               AugeasNode parentNode,
                                               net.augeas.Augeas augeas)
Overrides:
getAugeasPathRelativeToParent in class AugeasConfigurationComponent<PlatformComponent>

toPropertyValue

protected Object toPropertyValue(org.rhq.core.domain.configuration.definition.PropertyDefinitionSimple propDefSimple,
                                 net.augeas.Augeas augeas,
                                 AugeasNode node)
Overrides:
toPropertyValue in class AugeasConfigurationComponent<PlatformComponent>

updateCrontab

protected void updateCrontab(String crontabPath,
                             org.rhq.core.domain.configuration.definition.ConfigurationDefinition crontabConfigurationDefinition,
                             org.rhq.core.domain.configuration.Configuration crontabConfiguration)


Copyright © 2008-2012 Red Hat, Inc.. All Rights Reserved.