001/**
002 * Copyright 2005-2016 The Kuali Foundation
003 *
004 * Licensed under the Educational Community License, Version 2.0 (the "License");
005 * you may not use this file except in compliance with the License.
006 * You may obtain a copy of the License at
007 *
008 * http://www.opensource.org/licenses/ecl2.php
009 *
010 * Unless required by applicable law or agreed to in writing, software
011 * distributed under the License is distributed on an "AS IS" BASIS,
012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
013 * See the License for the specific language governing permissions and
014 * limitations under the License.
015 */
016package org.kuali.rice.krad.bo;
017
018import org.kuali.rice.core.api.mo.common.active.MutableInactivatable;
019
020import java.sql.Timestamp;
021
022/**
023 * Business objects that have effective dating (from to dates) should implement this interface. This
024 * translates the effective dates in terms of active/inactive status so the features built for
025 * {@link MutableInactivatable} in the frameworks can be taken advantage of
026 */
027public interface InactivatableFromTo extends MutableInactivatable {
028
029        /**
030         * Sets the date for which record will be active
031         * 
032         * @param from
033         *            - Timestamp value to set
034         */
035        public void setActiveFromDate(Timestamp from);
036        
037        /**
038         * Gets the date for which the record become active
039         *
040         * @return Timestamp
041         */
042        public Timestamp getActiveFromDate();
043
044        /**
045         * Sets the date for which record will be active to
046         * 
047         * @param from
048         *            - Timestamp value to set
049         */
050        public void setActiveToDate(Timestamp to);
051        
052        /**
053         * Gets the date for which the record become inactive
054         *
055         * @return Timestamp
056         */
057        public Timestamp getActiveToDate();
058
059        /**
060         * Gets the date for which the record is being compared to in determining active/inactive
061         * 
062         * @return Timestamp
063         */
064        public Timestamp getActiveAsOfDate();
065
066        /**
067         * Sets the date for which the record should be compared to in determining active/inactive, if
068         * not set then the current date will be used
069         * 
070         * @param activeAsOfDate
071         *            - Timestamp value to set
072         */
073        public void setActiveAsOfDate(Timestamp activeAsOfDate);
074
075}