Package com.yahoo.component.provider
Class FreezableClass
- java.lang.Object
-
- com.yahoo.component.provider.FreezableClass
-
- All Implemented Interfaces:
Freezable
- Direct Known Subclasses:
ListenableFreezableClass
public class FreezableClass extends Object implements Freezable
Convenience superclass of non-component freezables- Author:
- bratseth
-
-
Constructor Summary
Constructors Constructor Description FreezableClass()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description FreezableClass
clone()
Clones this.protected void
ensureNotFrozen()
Throws an IllegalStateException if this is frozenvoid
freeze()
Freezes this class to prevent further changes.boolean
isFrozen()
Returns whether this is currently frozen
-
-
-
Method Detail
-
freeze
public void freeze()
Freezes this class to prevent further changes. Override this to freeze internal data structures and dependent objects. Overrides must call super. Calling freeze on an already frozen registry must have no effect.
-
isFrozen
public final boolean isFrozen()
Returns whether this is currently frozen
-
ensureNotFrozen
protected void ensureNotFrozen()
Throws an IllegalStateException if this is frozen
-
clone
public FreezableClass clone()
Clones this. The clone is not frozen
-
-