Package clips.delegate.job

Source Code of clips.delegate.job.DangerExamChunk

/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/

package clips.delegate.job;

import clips.delegate.directory.complex.DirectoryDanger;
import clips.delegate.directory.complex.DirectoryDangerItem;
import cli_fmw.delegate.directory.complex.DirectoryLocator;
import cli_fmw.delegate.lists.DataChunk;
import cli_fmw.main.ClipsException;
import beans.user.job.entity.DangerJobDetails;
import java.io.Serializable;
import java.util.Date;

/**
*
* @author petr
*/
public class DangerExamChunk extends DataChunk<DangerJobDetails> implements Serializable, Cloneable{

    public DangerExamChunk(DangerJobDetails details) {
        super(details);
    }
   
    public DirectoryDangerItem getDanger() throws ClipsException{
        DirectoryDanger danger = DirectoryLocator.getDirectory(DirectoryDanger.class, false);
        return danger.getItemFromID(getDetails().dangerId);
    }
   
    public void setDanger(DirectoryDangerItem item){
        this.getDetails().dangerId = item.getID();
    }
   
    public Date getLastExam(){
        return this.getDetails().lastExam;
    }
   
    public void setLastExam(Date d){
        this.getDetails().lastExam = d;
        this.getDetails().lastExamManually = true;
    }
   
    public boolean isLastExamManually(){
        return this.getDetails().lastExamManually;
    }

}
TOP

Related Classes of clips.delegate.job.DangerExamChunk

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.