All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.enonic.xp.task.TaskNotFoundException Maven / Gradle / Ivy

There is a newer version: 7.14.4
Show newest version
package com.enonic.xp.task;

import java.text.MessageFormat;

import com.enonic.xp.annotation.PublicApi;
import com.enonic.xp.exception.BaseException;
import com.enonic.xp.page.DescriptorKey;

@PublicApi
public class TaskNotFoundException
    extends BaseException
{
    private final DescriptorKey task;

    public TaskNotFoundException( final DescriptorKey task )
    {
        super( MessageFormat.format( "Task [{0}] not found", task ) );
        this.task = task;
    }

    public TaskNotFoundException( final DescriptorKey task, final String message )
    {
        super( MessageFormat.format( "Task [{0}] not found. {1}", task, message ) );
        this.task = task;
    }

    public DescriptorKey getTask()
    {
        return task;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy