Class RepositoryJobInfo


  • public class RepositoryJobInfo
    extends Object
    Captures information about a repository job.

    Jobs have names and are grouped. A job must have a unique name within a given group. Jobs are triggered by RepositoryJobTriggers. Jobs can have multiple such triggers associated with them.

    • Constructor Detail

      • RepositoryJobInfo

        public RepositoryJobInfo​(String name,
                                 Class<? extends RepositoryJob> jobClass)
        Create a job within the default group.
        Parameters:
        name - the name of the job.
        jobClass - the class of the job to run.
      • RepositoryJobInfo

        public RepositoryJobInfo​(String name,
                                 String group,
                                 Class<? extends RepositoryJob> jobClass)
        Create a job.
        Parameters:
        name - the name of the job.
        group - the jobs group.
        jobClass - the class of the job to run
    • Method Detail

      • getName

        public String getName()
        Returns:
        the name of this job.
      • getGroup

        public String getGroup()
        Returns:
        the group name of this job.
      • getJobClass

        public Class<? extends RepositoryJob> getJobClass()
        Returns:
        the class of the job to run.
      • getAttribute

        public String getAttribute​(String name)
        Returns:
        the value of an attribute by name.
      • getAttributeNames

        public Collection<String> getAttributeNames()
        Returns:
        all the attributes that were added to this info.
      • createNode

        public javax.jcr.Node createNode​(javax.jcr.Session session)
                                  throws javax.jcr.RepositoryException
        Override the way the job node is created.
        Parameters:
        session - JCR session with which to create a new job node.
        Returns:
        a newly created node representing the job, or null to let the system create one.
        Throws:
        javax.jcr.RepositoryException