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 2005-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  
 package org.kuali.rice.core.api.mo.common.active;
 17  
 
 18  
 import org.joda.time.DateTime;
 19  
 
 20  
 import java.sql.Timestamp;
 21  
 
 22  
 /**
 23  
  * This interface can be used to identify a model object which has an
 24  
  * "active range" such that an object is only active with a certain
 25  
  * temporal range.
 26  
  *
 27  
  * @author Kuali Rice Team (rice.collab@kuali.org)
 28  
  */
 29  
 public interface InactivatableFromTo {
 30  
 
 31  
     /**
 32  
          * Gets the date for which the record become active. Can be null.
 33  
          *
 34  
          * @return Timestamp of active from date
 35  
          */
 36  
         DateTime getActiveFromDate();
 37  
 
 38  
         /**
 39  
          * Gets the date for which the record become inactive. Can be null.
 40  
          *
 41  
          * @return Timestamp of active to date
 42  
          */
 43  
         DateTime getActiveToDate();
 44  
 
 45  
     /**
 46  
      * Returns if the record is active for a given Time.
 47  
      * If the activeAsOfDate is null will return null.
 48  
      *
 49  
      * @return true if active false if not
 50  
      */
 51  
     boolean isActive(DateTime activeAsOfDate);
 52  
 }