001// --------------------------------------------------------------------------------
002// Copyright 2002-2026 Echo Three, LLC
003//
004// Licensed under the Apache 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.apache.org/licenses/LICENSE-2.0
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// --------------------------------------------------------------------------------
016// Generated File -- DO NOT EDIT BY HAND
017// --------------------------------------------------------------------------------
018
019/**
020 * InventoryTransactionLineDetailValue.java
021 */
022
023package com.echothree.model.data.inventory.server.value;
024
025import com.echothree.model.data.inventory.common.pk.InventoryTransactionLineDetailPK;
026
027import com.echothree.model.data.inventory.server.factory.InventoryTransactionLineDetailFactory;
028
029import com.echothree.model.data.inventory.common.pk.InventoryTransactionLinePK;
030import com.echothree.model.data.inventory.common.pk.InventoryTransactionPK;
031import com.echothree.model.data.inventory.common.pk.InventoryTransactionReasonPK;
032import com.echothree.model.data.item.common.pk.ItemPK;
033import com.echothree.model.data.inventory.common.pk.LotPK;
034import com.echothree.model.data.inventory.common.pk.InventoryAdjustmentTypePK;
035
036import com.echothree.util.common.exception.PersistenceCloneException;
037import com.echothree.util.common.exception.PersistenceNotNullException;
038
039import com.echothree.util.server.persistence.BaseValue;
040
041import java.io.Serializable;
042
043import javax.annotation.Nonnull;
044import javax.annotation.Nullable;
045
046public class InventoryTransactionLineDetailValue
047        extends BaseValue<InventoryTransactionLineDetailPK>
048        implements Cloneable, Serializable {
049    
050    private InventoryTransactionLinePK inventoryTransactionLinePK;
051    private boolean inventoryTransactionLinePKHasBeenModified = false;
052    private InventoryTransactionPK inventoryTransactionPK;
053    private boolean inventoryTransactionPKHasBeenModified = false;
054    private Integer inventoryTransactionLineSequence;
055    private boolean inventoryTransactionLineSequenceHasBeenModified = false;
056    private InventoryTransactionReasonPK inventoryTransactionReasonPK;
057    private boolean inventoryTransactionReasonPKHasBeenModified = false;
058    private ItemPK itemPK;
059    private boolean itemPKHasBeenModified = false;
060    private LotPK lotPK;
061    private boolean lotPKHasBeenModified = false;
062    private InventoryAdjustmentTypePK inventoryAdjustmentTypePK;
063    private boolean inventoryAdjustmentTypePKHasBeenModified = false;
064    private Long unitAmount;
065    private boolean unitAmountHasBeenModified = false;
066    private String description;
067    private boolean descriptionHasBeenModified = false;
068    private Long fromTime;
069    private boolean fromTimeHasBeenModified = false;
070    private Long thruTime;
071    private boolean thruTimeHasBeenModified = false;
072    
073    private transient Integer _hashCode = null;
074    private transient String _stringValue = null;
075    
076    private void constructFields(InventoryTransactionLinePK inventoryTransactionLinePK, InventoryTransactionPK inventoryTransactionPK, Integer inventoryTransactionLineSequence, InventoryTransactionReasonPK inventoryTransactionReasonPK, ItemPK itemPK, LotPK lotPK, InventoryAdjustmentTypePK inventoryAdjustmentTypePK, Long unitAmount, String description, Long fromTime, Long thruTime)
077            throws PersistenceNotNullException {
078        checkForNull(inventoryTransactionLinePK);
079        this.inventoryTransactionLinePK = inventoryTransactionLinePK;
080        checkForNull(inventoryTransactionPK);
081        this.inventoryTransactionPK = inventoryTransactionPK;
082        checkForNull(inventoryTransactionLineSequence);
083        this.inventoryTransactionLineSequence = inventoryTransactionLineSequence;
084        this.inventoryTransactionReasonPK = inventoryTransactionReasonPK;
085        checkForNull(itemPK);
086        this.itemPK = itemPK;
087        this.lotPK = lotPK;
088        checkForNull(inventoryAdjustmentTypePK);
089        this.inventoryAdjustmentTypePK = inventoryAdjustmentTypePK;
090        this.unitAmount = unitAmount;
091        this.description = description;
092        checkForNull(fromTime);
093        this.fromTime = fromTime;
094        checkForNull(thruTime);
095        this.thruTime = thruTime;
096    }
097    
098    /** Creates a new instance of InventoryTransactionLineDetailValue */
099    public InventoryTransactionLineDetailValue(InventoryTransactionLineDetailPK inventoryTransactionLineDetailPK, InventoryTransactionLinePK inventoryTransactionLinePK, InventoryTransactionPK inventoryTransactionPK, Integer inventoryTransactionLineSequence, InventoryTransactionReasonPK inventoryTransactionReasonPK, ItemPK itemPK, LotPK lotPK, InventoryAdjustmentTypePK inventoryAdjustmentTypePK, Long unitAmount, String description, Long fromTime, Long thruTime)
100            throws PersistenceNotNullException {
101        super(inventoryTransactionLineDetailPK);
102        constructFields(inventoryTransactionLinePK, inventoryTransactionPK, inventoryTransactionLineSequence, inventoryTransactionReasonPK, itemPK, lotPK, inventoryAdjustmentTypePK, unitAmount, description, fromTime, thruTime);
103    }
104    
105    /** Creates a new instance of InventoryTransactionLineDetailValue */
106    public InventoryTransactionLineDetailValue(InventoryTransactionLinePK inventoryTransactionLinePK, InventoryTransactionPK inventoryTransactionPK, Integer inventoryTransactionLineSequence, InventoryTransactionReasonPK inventoryTransactionReasonPK, ItemPK itemPK, LotPK lotPK, InventoryAdjustmentTypePK inventoryAdjustmentTypePK, Long unitAmount, String description, Long fromTime, Long thruTime)
107            throws PersistenceNotNullException {
108        super();
109        constructFields(inventoryTransactionLinePK, inventoryTransactionPK, inventoryTransactionLineSequence, inventoryTransactionReasonPK, itemPK, lotPK, inventoryAdjustmentTypePK, unitAmount, description, fromTime, thruTime);
110    }
111    
112    @Override
113    @Nonnull
114    public InventoryTransactionLineDetailFactory getBaseFactoryInstance() {
115        return InventoryTransactionLineDetailFactory.getInstance();
116    }
117    
118    @Override
119    @Nonnull
120    public InventoryTransactionLineDetailValue clone() {
121        Object result;
122        
123        try {
124            result = super.clone();
125        } catch (CloneNotSupportedException cnse) {
126            // This shouldn't happen, fail when it does.
127            throw new PersistenceCloneException(cnse);
128        }
129        
130        return (InventoryTransactionLineDetailValue)result;
131    }
132    
133    @Override
134    @Nonnull
135    public InventoryTransactionLineDetailPK getPrimaryKey() {
136        if(_primaryKey == null) {
137            _primaryKey = new InventoryTransactionLineDetailPK(entityId);
138        }
139        
140        return _primaryKey;
141    }
142    
143    private void clearHashAndString() {
144        _hashCode = null;
145        _stringValue = null;
146    }
147    
148    @Override
149    public int hashCode() {
150        if(_hashCode == null) {
151            int hashCode = 17;
152            
153            hashCode = 37 * hashCode + ((entityId != null) ? entityId.hashCode() : 0);
154            
155            hashCode = 37 * hashCode + ((inventoryTransactionLinePK != null) ? inventoryTransactionLinePK.hashCode() : 0);
156            hashCode = 37 * hashCode + ((inventoryTransactionPK != null) ? inventoryTransactionPK.hashCode() : 0);
157            hashCode = 37 * hashCode + ((inventoryTransactionLineSequence != null) ? inventoryTransactionLineSequence.hashCode() : 0);
158            hashCode = 37 * hashCode + ((inventoryTransactionReasonPK != null) ? inventoryTransactionReasonPK.hashCode() : 0);
159            hashCode = 37 * hashCode + ((itemPK != null) ? itemPK.hashCode() : 0);
160            hashCode = 37 * hashCode + ((lotPK != null) ? lotPK.hashCode() : 0);
161            hashCode = 37 * hashCode + ((inventoryAdjustmentTypePK != null) ? inventoryAdjustmentTypePK.hashCode() : 0);
162            hashCode = 37 * hashCode + ((unitAmount != null) ? unitAmount.hashCode() : 0);
163            hashCode = 37 * hashCode + ((description != null) ? description.hashCode() : 0);
164            hashCode = 37 * hashCode + ((fromTime != null) ? fromTime.hashCode() : 0);
165            hashCode = 37 * hashCode + ((thruTime != null) ? thruTime.hashCode() : 0);
166            
167            _hashCode = hashCode;
168        }
169        
170        return _hashCode;
171    }
172    
173    @Override
174    @Nonnull
175    public String toString() {
176        if(_stringValue == null) {
177            _stringValue = "{" + 
178                    "entityId=" + getEntityId() +
179                    ", inventoryTransactionLinePK=" + getInventoryTransactionLinePK() +
180                    ", inventoryTransactionPK=" + getInventoryTransactionPK() +
181                    ", inventoryTransactionLineSequence=" + getInventoryTransactionLineSequence() +
182                    ", inventoryTransactionReasonPK=" + getInventoryTransactionReasonPK() +
183                    ", itemPK=" + getItemPK() +
184                    ", lotPK=" + getLotPK() +
185                    ", inventoryAdjustmentTypePK=" + getInventoryAdjustmentTypePK() +
186                    ", unitAmount=" + getUnitAmount() +
187                    ", description=" + getDescription() +
188                    ", fromTime=" + getFromTime() +
189                    ", thruTime=" + getThruTime() +
190                    "}";
191        }
192        return _stringValue;
193    }
194    
195    @Override
196    public boolean equals(Object other) {
197        if(this == other)
198            return true;
199        
200        if(!hasIdentity())
201            return false;
202        
203        if(other instanceof  InventoryTransactionLineDetailValue that) {
204            if(!that.hasIdentity())
205                return false;
206            
207            Long thisEntityId = getEntityId();
208            Long thatEntityId = that.getEntityId();
209            
210            boolean objectsEqual = thisEntityId.equals(thatEntityId);
211            if(objectsEqual)
212                objectsEqual = isIdentical(that);
213            
214            return objectsEqual;
215        } else {
216            return false;
217        }
218    }
219    
220    public boolean isIdentical(Object other) {
221        if(other instanceof InventoryTransactionLineDetailValue that) {
222            boolean objectsEqual = true;
223            
224            
225            if(objectsEqual) {
226                InventoryTransactionLinePK thisInventoryTransactionLinePK = getInventoryTransactionLinePK();
227                InventoryTransactionLinePK thatInventoryTransactionLinePK = that.getInventoryTransactionLinePK();
228                
229                if(thisInventoryTransactionLinePK == null) {
230                    objectsEqual = objectsEqual && (thatInventoryTransactionLinePK == null);
231                } else {
232                    objectsEqual = objectsEqual && thisInventoryTransactionLinePK.equals(thatInventoryTransactionLinePK);
233                }
234            }
235            
236            if(objectsEqual) {
237                InventoryTransactionPK thisInventoryTransactionPK = getInventoryTransactionPK();
238                InventoryTransactionPK thatInventoryTransactionPK = that.getInventoryTransactionPK();
239                
240                if(thisInventoryTransactionPK == null) {
241                    objectsEqual = objectsEqual && (thatInventoryTransactionPK == null);
242                } else {
243                    objectsEqual = objectsEqual && thisInventoryTransactionPK.equals(thatInventoryTransactionPK);
244                }
245            }
246            
247            if(objectsEqual) {
248                Integer thisInventoryTransactionLineSequence = getInventoryTransactionLineSequence();
249                Integer thatInventoryTransactionLineSequence = that.getInventoryTransactionLineSequence();
250                
251                if(thisInventoryTransactionLineSequence == null) {
252                    objectsEqual = objectsEqual && (thatInventoryTransactionLineSequence == null);
253                } else {
254                    objectsEqual = objectsEqual && thisInventoryTransactionLineSequence.equals(thatInventoryTransactionLineSequence);
255                }
256            }
257            
258            if(objectsEqual) {
259                InventoryTransactionReasonPK thisInventoryTransactionReasonPK = getInventoryTransactionReasonPK();
260                InventoryTransactionReasonPK thatInventoryTransactionReasonPK = that.getInventoryTransactionReasonPK();
261                
262                if(thisInventoryTransactionReasonPK == null) {
263                    objectsEqual = objectsEqual && (thatInventoryTransactionReasonPK == null);
264                } else {
265                    objectsEqual = objectsEqual && thisInventoryTransactionReasonPK.equals(thatInventoryTransactionReasonPK);
266                }
267            }
268            
269            if(objectsEqual) {
270                ItemPK thisItemPK = getItemPK();
271                ItemPK thatItemPK = that.getItemPK();
272                
273                if(thisItemPK == null) {
274                    objectsEqual = objectsEqual && (thatItemPK == null);
275                } else {
276                    objectsEqual = objectsEqual && thisItemPK.equals(thatItemPK);
277                }
278            }
279            
280            if(objectsEqual) {
281                LotPK thisLotPK = getLotPK();
282                LotPK thatLotPK = that.getLotPK();
283                
284                if(thisLotPK == null) {
285                    objectsEqual = objectsEqual && (thatLotPK == null);
286                } else {
287                    objectsEqual = objectsEqual && thisLotPK.equals(thatLotPK);
288                }
289            }
290            
291            if(objectsEqual) {
292                InventoryAdjustmentTypePK thisInventoryAdjustmentTypePK = getInventoryAdjustmentTypePK();
293                InventoryAdjustmentTypePK thatInventoryAdjustmentTypePK = that.getInventoryAdjustmentTypePK();
294                
295                if(thisInventoryAdjustmentTypePK == null) {
296                    objectsEqual = objectsEqual && (thatInventoryAdjustmentTypePK == null);
297                } else {
298                    objectsEqual = objectsEqual && thisInventoryAdjustmentTypePK.equals(thatInventoryAdjustmentTypePK);
299                }
300            }
301            
302            if(objectsEqual) {
303                Long thisUnitAmount = getUnitAmount();
304                Long thatUnitAmount = that.getUnitAmount();
305                
306                if(thisUnitAmount == null) {
307                    objectsEqual = objectsEqual && (thatUnitAmount == null);
308                } else {
309                    objectsEqual = objectsEqual && thisUnitAmount.equals(thatUnitAmount);
310                }
311            }
312            
313            if(objectsEqual) {
314                String thisDescription = getDescription();
315                String thatDescription = that.getDescription();
316                
317                if(thisDescription == null) {
318                    objectsEqual = objectsEqual && (thatDescription == null);
319                } else {
320                    objectsEqual = objectsEqual && thisDescription.equals(thatDescription);
321                }
322            }
323            
324            if(objectsEqual) {
325                Long thisFromTime = getFromTime();
326                Long thatFromTime = that.getFromTime();
327                
328                if(thisFromTime == null) {
329                    objectsEqual = objectsEqual && (thatFromTime == null);
330                } else {
331                    objectsEqual = objectsEqual && thisFromTime.equals(thatFromTime);
332                }
333            }
334            
335            if(objectsEqual) {
336                Long thisThruTime = getThruTime();
337                Long thatThruTime = that.getThruTime();
338                
339                if(thisThruTime == null) {
340                    objectsEqual = objectsEqual && (thatThruTime == null);
341                } else {
342                    objectsEqual = objectsEqual && thisThruTime.equals(thatThruTime);
343                }
344            }
345            
346            return objectsEqual;
347        } else {
348            return false;
349        }
350    }
351    
352    @Override
353    public boolean hasBeenModified() {
354        return inventoryTransactionLinePKHasBeenModified || inventoryTransactionPKHasBeenModified || inventoryTransactionLineSequenceHasBeenModified || inventoryTransactionReasonPKHasBeenModified || itemPKHasBeenModified || lotPKHasBeenModified || inventoryAdjustmentTypePKHasBeenModified || unitAmountHasBeenModified || descriptionHasBeenModified || fromTimeHasBeenModified || thruTimeHasBeenModified;
355    }
356    
357    @Override
358    public void clearHasBeenModified() {
359        inventoryTransactionLinePKHasBeenModified = false;
360        inventoryTransactionPKHasBeenModified = false;
361        inventoryTransactionLineSequenceHasBeenModified = false;
362        inventoryTransactionReasonPKHasBeenModified = false;
363        itemPKHasBeenModified = false;
364        lotPKHasBeenModified = false;
365        inventoryAdjustmentTypePKHasBeenModified = false;
366        unitAmountHasBeenModified = false;
367        descriptionHasBeenModified = false;
368        fromTimeHasBeenModified = false;
369        thruTimeHasBeenModified = false;
370    }
371    
372    @Nonnull
373    public InventoryTransactionLinePK getInventoryTransactionLinePK() {
374        return inventoryTransactionLinePK;
375    }
376    
377    public void setInventoryTransactionLinePK(@Nonnull InventoryTransactionLinePK inventoryTransactionLinePK)
378            throws PersistenceNotNullException {
379        checkForNull(inventoryTransactionLinePK);
380        
381        boolean update = true;
382        
383        if(this.inventoryTransactionLinePK != null) {
384            if(this.inventoryTransactionLinePK.equals(inventoryTransactionLinePK)) {
385                update = false;
386            }
387        } else if(inventoryTransactionLinePK == null) {
388            update = false;
389        }
390        
391        if(update) {
392            this.inventoryTransactionLinePK = inventoryTransactionLinePK;
393            inventoryTransactionLinePKHasBeenModified = true;
394            clearHashAndString();
395        }
396    }
397    
398    public boolean getInventoryTransactionLinePKHasBeenModified() {
399        return inventoryTransactionLinePKHasBeenModified;
400    }
401    
402    @Nonnull
403    public InventoryTransactionPK getInventoryTransactionPK() {
404        return inventoryTransactionPK;
405    }
406    
407    public void setInventoryTransactionPK(@Nonnull InventoryTransactionPK inventoryTransactionPK)
408            throws PersistenceNotNullException {
409        checkForNull(inventoryTransactionPK);
410        
411        boolean update = true;
412        
413        if(this.inventoryTransactionPK != null) {
414            if(this.inventoryTransactionPK.equals(inventoryTransactionPK)) {
415                update = false;
416            }
417        } else if(inventoryTransactionPK == null) {
418            update = false;
419        }
420        
421        if(update) {
422            this.inventoryTransactionPK = inventoryTransactionPK;
423            inventoryTransactionPKHasBeenModified = true;
424            clearHashAndString();
425        }
426    }
427    
428    public boolean getInventoryTransactionPKHasBeenModified() {
429        return inventoryTransactionPKHasBeenModified;
430    }
431    
432    @Nonnull
433    public Integer getInventoryTransactionLineSequence() {
434        return inventoryTransactionLineSequence;
435    }
436    
437    public void setInventoryTransactionLineSequence(@Nonnull Integer inventoryTransactionLineSequence)
438            throws PersistenceNotNullException {
439        checkForNull(inventoryTransactionLineSequence);
440        
441        boolean update = true;
442        
443        if(this.inventoryTransactionLineSequence != null) {
444            if(this.inventoryTransactionLineSequence.equals(inventoryTransactionLineSequence)) {
445                update = false;
446            }
447        } else if(inventoryTransactionLineSequence == null) {
448            update = false;
449        }
450        
451        if(update) {
452            this.inventoryTransactionLineSequence = inventoryTransactionLineSequence;
453            inventoryTransactionLineSequenceHasBeenModified = true;
454            clearHashAndString();
455        }
456    }
457    
458    public boolean getInventoryTransactionLineSequenceHasBeenModified() {
459        return inventoryTransactionLineSequenceHasBeenModified;
460    }
461    
462    @Nullable
463    public InventoryTransactionReasonPK getInventoryTransactionReasonPK() {
464        return inventoryTransactionReasonPK;
465    }
466    
467    public void setInventoryTransactionReasonPK(@Nullable InventoryTransactionReasonPK inventoryTransactionReasonPK) {
468        boolean update = true;
469        
470        if(this.inventoryTransactionReasonPK != null) {
471            if(this.inventoryTransactionReasonPK.equals(inventoryTransactionReasonPK)) {
472                update = false;
473            }
474        } else if(inventoryTransactionReasonPK == null) {
475            update = false;
476        }
477        
478        if(update) {
479            this.inventoryTransactionReasonPK = inventoryTransactionReasonPK;
480            inventoryTransactionReasonPKHasBeenModified = true;
481            clearHashAndString();
482        }
483    }
484    
485    public boolean getInventoryTransactionReasonPKHasBeenModified() {
486        return inventoryTransactionReasonPKHasBeenModified;
487    }
488    
489    @Nonnull
490    public ItemPK getItemPK() {
491        return itemPK;
492    }
493    
494    public void setItemPK(@Nonnull ItemPK itemPK)
495            throws PersistenceNotNullException {
496        checkForNull(itemPK);
497        
498        boolean update = true;
499        
500        if(this.itemPK != null) {
501            if(this.itemPK.equals(itemPK)) {
502                update = false;
503            }
504        } else if(itemPK == null) {
505            update = false;
506        }
507        
508        if(update) {
509            this.itemPK = itemPK;
510            itemPKHasBeenModified = true;
511            clearHashAndString();
512        }
513    }
514    
515    public boolean getItemPKHasBeenModified() {
516        return itemPKHasBeenModified;
517    }
518    
519    @Nullable
520    public LotPK getLotPK() {
521        return lotPK;
522    }
523    
524    public void setLotPK(@Nullable LotPK lotPK) {
525        boolean update = true;
526        
527        if(this.lotPK != null) {
528            if(this.lotPK.equals(lotPK)) {
529                update = false;
530            }
531        } else if(lotPK == null) {
532            update = false;
533        }
534        
535        if(update) {
536            this.lotPK = lotPK;
537            lotPKHasBeenModified = true;
538            clearHashAndString();
539        }
540    }
541    
542    public boolean getLotPKHasBeenModified() {
543        return lotPKHasBeenModified;
544    }
545    
546    @Nonnull
547    public InventoryAdjustmentTypePK getInventoryAdjustmentTypePK() {
548        return inventoryAdjustmentTypePK;
549    }
550    
551    public void setInventoryAdjustmentTypePK(@Nonnull InventoryAdjustmentTypePK inventoryAdjustmentTypePK)
552            throws PersistenceNotNullException {
553        checkForNull(inventoryAdjustmentTypePK);
554        
555        boolean update = true;
556        
557        if(this.inventoryAdjustmentTypePK != null) {
558            if(this.inventoryAdjustmentTypePK.equals(inventoryAdjustmentTypePK)) {
559                update = false;
560            }
561        } else if(inventoryAdjustmentTypePK == null) {
562            update = false;
563        }
564        
565        if(update) {
566            this.inventoryAdjustmentTypePK = inventoryAdjustmentTypePK;
567            inventoryAdjustmentTypePKHasBeenModified = true;
568            clearHashAndString();
569        }
570    }
571    
572    public boolean getInventoryAdjustmentTypePKHasBeenModified() {
573        return inventoryAdjustmentTypePKHasBeenModified;
574    }
575    
576    @Nullable
577    public Long getUnitAmount() {
578        return unitAmount;
579    }
580    
581    public void setUnitAmount(@Nullable Long unitAmount) {
582        boolean update = true;
583        
584        if(this.unitAmount != null) {
585            if(this.unitAmount.equals(unitAmount)) {
586                update = false;
587            }
588        } else if(unitAmount == null) {
589            update = false;
590        }
591        
592        if(update) {
593            this.unitAmount = unitAmount;
594            unitAmountHasBeenModified = true;
595            clearHashAndString();
596        }
597    }
598    
599    public boolean getUnitAmountHasBeenModified() {
600        return unitAmountHasBeenModified;
601    }
602    
603    @Nullable
604    public String getDescription() {
605        return description;
606    }
607    
608    public void setDescription(@Nullable String description) {
609        boolean update = true;
610        
611        if(this.description != null) {
612            if(this.description.equals(description)) {
613                update = false;
614            }
615        } else if(description == null) {
616            update = false;
617        }
618        
619        if(update) {
620            this.description = description;
621            descriptionHasBeenModified = true;
622            clearHashAndString();
623        }
624    }
625    
626    public boolean getDescriptionHasBeenModified() {
627        return descriptionHasBeenModified;
628    }
629    
630    @Nonnull
631    public Long getFromTime() {
632        return fromTime;
633    }
634    
635    public void setFromTime(@Nonnull Long fromTime)
636            throws PersistenceNotNullException {
637        checkForNull(fromTime);
638        
639        boolean update = true;
640        
641        if(this.fromTime != null) {
642            if(this.fromTime.equals(fromTime)) {
643                update = false;
644            }
645        } else if(fromTime == null) {
646            update = false;
647        }
648        
649        if(update) {
650            this.fromTime = fromTime;
651            fromTimeHasBeenModified = true;
652            clearHashAndString();
653        }
654    }
655    
656    public boolean getFromTimeHasBeenModified() {
657        return fromTimeHasBeenModified;
658    }
659    
660    @Nonnull
661    public Long getThruTime() {
662        return thruTime;
663    }
664    
665    public void setThruTime(@Nonnull Long thruTime)
666            throws PersistenceNotNullException {
667        checkForNull(thruTime);
668        
669        boolean update = true;
670        
671        if(this.thruTime != null) {
672            if(this.thruTime.equals(thruTime)) {
673                update = false;
674            }
675        } else if(thruTime == null) {
676            update = false;
677        }
678        
679        if(update) {
680            this.thruTime = thruTime;
681            thruTimeHasBeenModified = true;
682            clearHashAndString();
683        }
684    }
685    
686    public boolean getThruTimeHasBeenModified() {
687        return thruTimeHasBeenModified;
688    }
689    
690}