Coverage Report - org.kuali.rice.core.api.mo.common.active.InactivatableFromTo
 
Classes in this File Line Coverage Branch Coverage Complexity
InactivatableFromTo
N/A
N/A
1
 
 1  
 /*
 2  
  * Copyright 2006-2011 The Kuali Foundation
 3  
  *
 4  
  * Licensed under the Educational Community License, Version 2.0 (the "License");
 5  
  * you may not use this file except in compliance with the License.
 6  
  * You may obtain a copy of the License at
 7  
  *
 8  
  * http://www.opensource.org/licenses/ecl2.php
 9  
  *
 10  
  * Unless required by applicable law or agreed to in writing, software
 11  
  * distributed under the License is distributed on an "AS IS" BASIS,
 12  
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 13  
  * See the License for the specific language governing permissions and
 14  
  * limitations under the License.
 15  
  */
 16  
 
 17  
 package org.kuali.rice.core.api.mo.common.active;
 18  
 
 19  
 import org.joda.time.DateTime;
 20  
 
 21  
 import java.sql.Timestamp;
 22  
 
 23  
 /**
 24  
  * This interface can be used to identify a model object which has an
 25  
  * "active range" such that an object is only active with a certain
 26  
  * temporal range.
 27  
  *
 28  
  * @author Kuali Rice Team (rice.collab@kuali.org)
 29  
  */
 30  
 public interface InactivatableFromTo {
 31  
 
 32  
     /**
 33  
          * Gets the date for which the record become active. Can be null.
 34  
          *
 35  
          * @return Timestamp of active from date
 36  
          */
 37  
         DateTime getActiveFromDate();
 38  
 
 39  
         /**
 40  
          * Gets the date for which the record become inactive. Can be null.
 41  
          *
 42  
          * @return Timestamp of active to date
 43  
          */
 44  
         DateTime getActiveToDate();
 45  
 
 46  
     /**
 47  
      * Returns if the record is active for a given Time.
 48  
      * If the activeAsOfDate is null will return null.
 49  
      *
 50  
      * @return true if active false if not
 51  
      */
 52  
     boolean isActive(DateTime activeAsOfDate);
 53  
 }